﻿import QtQuick 2.7
import QtQuick.Window 2.2
import QtQuick.Controls 2.0
import Warn 1.0
import GasFlow 1.0
import Particulate 1.0
import OtherParameter 1.0
import User 1.0
Rectangle{

    //id:head;
    x:0;y:0;
    width: 1280; height: 25;
    color:"cadetblue";
    border.color: "black";
    border.width: 1;
//参数初始化
    property int a: 0
    property string gas: "null"//确定气体种类(用于弹窗)
    property string database_gas: "null"//确定数据库气体名称
    property string gas_flow: "null"//确定烟气流量种类
    property string parti_name:"null"
    property int guolu: 0//确定锅炉号
    property string superhighwarn: "null"//报警参数
    property string highwarn:"null"
    property string lowwarn:"null"
    property string superlowwarn:"null"
    property string deadwarn:"null"
    property string declinewarn:"null"
    property string increasewarn:"null"
    property string pitot1: "null"
    property string velocity1: "null"
    property string sectional1: "null"
    property string pitot2: "null"
    property string velocity2: "null"
    property string sectional2: "null"
    property string dusta1: "null"
    property string dustb1: "null"
    property string dustc1: "null"
    property string dusta2: "null"
    property string dustb2: "null"
    property string dustc2: "null"
    property string atmos_press: "null"
    property string atmos_para: "null"
    Warninfo{id :warninfo}
    Gasflow{id:gasflow}
    Particulate{id:particu}
    OtherParameter{id : otherpara}

    Rectangle{
        id:login;
        x:10;y:1;
        width: 140; height: 25;
        color:"darkblue";

        Text {
            text: "用户登录"
            anchors.centerIn: parent;
            color: "white"
            font.family: "Ubuntu"
            font.pixelSize: 20
        }
        MouseArea{
            anchors.fill: parent
            onClicked: {
                a=user2.getauthority()
                if(a==1||a==2||a==3)
                    stack.pop()
                if(a==0){
                if(stack.depth > 0)stack.clear();
                stack.push(Qt.resolvedUrl("qrc:Welcome.qml"))
                }
            }
        }
    }
    Rectangle{
        x:login.x+160;y:1;
        width: 140; height: 25;
        color:"darkblue";
        Text {
            text: "主画面"
            anchors.centerIn: parent;
            color: "white";
            font.family: "Ubuntu";
            font.pixelSize: 20;
        }
        MouseArea{
            anchors.fill: parent
            onClicked: {  
              if(stack.depth > 0)stack.pop();
              stack.push(Qt.resolvedUrl("qrc:MainScreen.qml"))

            }
        }
    }
    Rectangle{
        x:login.x+160*2;y:1;
        width: 140; height: 25;
        color:"darkblue";
        Text {
            text: "参数设置"
            anchors.centerIn: parent;
            color: "white"
            font.family: "Ubuntu"
            font.pixelSize: 20
        }
        MouseArea{
            anchors.fill: parent
            onClicked: {
               a=user2.getauthority()
                //console.log(a);
                if(a==3||a==2)
//                if(stack.depth > 0)stack.clear();
//                stack.push(Qt.resolvedUrl("qrc:ParameterSetting.qml"))
               {

                    gasflow.selectGasflowbyid("1")
                    pitot1=gasflow.getpitot()
                    velocity1=gasflow.getvelocity()
                    sectional1=gasflow.getsectional()
                    gasflow.selectGasflowbyid("2")
                    pitot2=gasflow.getpitot()
                    velocity2=gasflow.getvelocity()
                    sectional2=gasflow.getsectional()
                    particu.selectParticulatebyid("1")
                    dusta1=particu.getdust_a()
                    dustb1=particu.getdust_b()
                    dustc1=particu.getdust_c()
                    particu.selectParticulatebyid("2")
                    dusta2=particu.getdust_a()
                    dustb2=particu.getdust_b()
                    dustc2=particu.getdust_c()
                    parameterSet.open()
                    otherpara.selectParameter()
                    atmos_press=otherpara.getatmos_press()
                    atmos_para=otherpara.getatmos_para()
                }
                if(a==1||a==0){
                    login_control.open()
                }

            }
        }
    }
    Rectangle{
        x:login.x+160*3;y:1;
        width: 140; height: 25;
        color:"darkblue";
        Text {
            text: "实时曲线"
            anchors.centerIn: parent;
            color: "white"
            font.family: "Ubuntu"
            font.pixelSize: 20
        }
        MouseArea{
            anchors.fill: parent
            onClicked: {
                a=user2.getauthority()
                if(a==3||a==2||a==1){
                    if(stack.depth > 0)stack.pop();
                    stack.push(Qt.resolvedUrl("qrc:Realtime.qml"))
                }
                if(a==0){
                    login_control.open()
                }

            }
        }
    }
    Rectangle{
        x:login.x+160*4;y:1;
        width: 140; height: 25;
        color:"darkblue";
        Text {
            text: "历史数据";
            anchors.centerIn: parent;
            color: "white";
            font.family: "Ubuntu";
            font.pixelSize: 20
        }
        MouseArea{
            anchors.fill: parent
            onClicked: {
                a=user2.getauthority()
                if(a==3||a==2||a==1){
                    if(stack.depth > 0)stack.pop();
                    stack.push(Qt.resolvedUrl("qrc:History.qml"))
                }
                if(a==0){
                    login_control.open()
                }

            }
        }
    }
    Rectangle{
        x:login.x+160*5;y:1;
        width: 140; height: 25;
        color:"darkblue";
        Text {
            text: "报警信息";
            anchors.centerIn: parent;
            color: "white";
            font.family: "Ubuntu";
            font.pixelSize: 20
        }
        MouseArea{
            anchors.fill: parent
            onClicked: {
                a=user2.getauthority()
                if(a==3||a==2||a==1){
                    if(stack.depth > 0)stack.pop();
                    stack.push(Qt.resolvedUrl("qrc:WaringInfo.qml"))
                }
                if(a==0){
                    login_control.open()
                }

            }
        }
    }
    Rectangle{
        x:login.x+160*6;y:1;
        width: 140; height: 25;
        color:"darkblue";
        Text {
            text: "系统流程"
            anchors.centerIn: parent;
            color: "white"
            font.family: "Ubuntu"
            font.pixelSize: 20
        }
        MouseArea{
            anchors.fill: parent
            onClicked: {
                a=user2.getauthority()
                if(a==3||a==2||a==1){
                    if(stack.depth > 0)stack.pop();
                    stack.push(Qt.resolvedUrl("qrc:SystemProcess.qml"))
                }
                if(a==0){
                    login_control.open()
                }

            }
        }
    }
    Rectangle{
        x:login.x+160*7;y:1;
        width: 140; height: 25;
        color:"darkblue";
        Text {
            text: "退出系统"
            anchors.centerIn: parent;
            color: "white"
            font.family: "Ubuntu"
            font.pixelSize: 20
        }
        MouseArea{
            anchors.fill: parent
            onClicked:{
                a=user2.getauthority()
                if(a==3||a==2){
                   Qt.quit()
                }
                if(a==1||a==0){
                    login_control.open()
                }

            }
        }
    }



    Popup{
        width: 1280
        height: 800
        id:parameterSet
        topPadding: 0
        leftPadding: 0
        rightPadding: 0
        bottomPadding: 0


//        flags:Qt.FramelessWindowHint |      //隐藏框框，标题栏等
//              Qt.WindowSystemMenuHint |     //隐藏系统菜单
//              Qt.WindowMinimizeButtonHint   //隐藏最大化最小化按钮
//        visible: true
        Rectangle{
            width: 1280
            height:800
            color: "cadetblue"
            Rectangle {
                id: rec1 //退出参数设置一行
                height: 30
                width: parent.width
                anchors.top: parent.top
                anchors.bottom: rec22.top
                color: "cadetblue"
                // @disable-check M300
                Button {
                    anchors.centerIn: rec1.Center
                    anchors.right: parent.right
                    width: 120
                    height: 20
                    text: "退出参数设置"
                    font.family: "Ubuntu"
                    font.pixelSize: 15
                    onClicked: {
                        parameterSet.close()
                    }
                }
            }

            Rectangle {
                id: rec20 //系统状态一行
                x: 30
                width: 210
                height: 80
                color: "cadetblue"

                anchors.top: rec1.bottom
                anchors.rightMargin: 105
                Rectangle {
                    x: 20
                    y: 10
                    height: 50
                    width: 140
                    color: "cadetblue"
                    border.color: "black"
                    Text {
                        text: " 参 数 设 置 "
                        anchors.centerIn: parent
                        color: "yellow"
                        font.family: "Ubuntu"
                        font.pixelSize: 20
                    }
                }
            }
            Rectangle {
                id: rec21 //系统状态一行
                height: 80
                width: 640
                color: "cadetblue"
                anchors.left: rec20.right
                anchors.top: rec1.bottom
                Text {
                    text: "系统状态"
                    color: "yellow"
                    font.family: "Ubuntu"
                    font.pixelSize: 20
                    y: 3
                    anchors.horizontalCenter: parent.horizontalCenter
                }
                Rectangle {
                    y: 40
                    anchors.horizontalCenter: parent.horizontalCenter
                    width: 500
                    height: 30
                    color: "cadetblue"

                    Rectangle {
                        x: 50
                        y: 5
                        width: 130
                        height: 20
                        color: "#CCEEFF"
                    }
                    Rectangle {
                        x: 195
                        y: 5
                        width: 130
                        height: 20
                        color: "#CCEEFF"
                    }
                    Rectangle {
                        x: 340
                        y: 5
                        width: 130
                        height: 20
                        color: "#CCEEFF"
                    }
                }
                Rectangle {
                    id: rec22 //系统状态一行
                    height: 40
                    width:210
                    anchors.leftMargin: 60
                    color: "cadetblue"
                    clip: true

                    anchors.top: rec1.bottom
                    anchors.left: rec21.right
                    Text {
                        text: "默认时间段，可设置系统时钟"
                        color: "yellow"
                        font.family: "Ubuntu"
                        font.pixelSize: 15
                        y: 15
                    }
                }
                Rectangle {
                    id: rec23 //系统状态一行
                    height: 40
                    width: 210
                    anchors.leftMargin: 60
                    anchors.top: rec22.bottom
                    anchors.left: rec21.right
                    color: "black"
                    Timer {
                        interval: 500; running: true; repeat: true
                        onTriggered: time.text = Qt.formatDateTime(new Date(),
                                                "yyyy-MM-dd hh:mm:ss")
                    }
                    Text {
                        id:time
                        anchors.centerIn: parent
                        color: "yellow"
                        font.family: "Ubuntu"
                        font.pixelSize: 15
                    }
                }
            }
            Rectangle {
                id: rec3
                height: 687
                width: parent.width
                border.color: "yellow"
                border.width: 1
                y: 113
                color: "cadetblue"
                Rectangle {
                    id: rec31 //报警设定部分
                    width: 400
                    height: 675
                    color: "cadetblue"
                    border.color: "black"
                    x: 5
                    y: 6
                    Rectangle {
                        id: rec310 //1#锅炉报警设定部分
                        width: 400
                        height: parent.height / 2
                        color: "cadetblue"
                        border.color: "black"
                        border.width: 1
                        Rectangle {
                            id: rec3100 //报警设定一列
                            height: parent.height - 2
                            width: 98
                            color: "cadetblue"
                            anchors.left: parent.left
                            anchors.leftMargin: 1
                            anchors.top: parent.top
                            anchors.topMargin: 1
                            Rectangle {
                                id: b0
                                x: 20
                                y: 5
                                width: 80
                                height: 20
                                color: "cadetblue"
                                Text {
                                    text: "报警设定"
                                    color: "yellow"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    anchors.centerIn: parent
                                }
                            }
                            Rectangle {
                                id: b1
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: b0.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "SO2"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="SO2"
                                        database_gas="SO2"
                                        warninfo.selectWarnInfobyName(database_gas)
                                        superhighwarn=warninfo.getsuperhigh_warn()
                                        highwarn=warninfo.gethigh_warn();
                                        lowwarn=warninfo.getlow_warn();
                                        superlowwarn=warninfo.getsuperlow_warn()
                                        deadwarn=warninfo.getdead_zone();
                                        declinewarn=warninfo.getdecline_warn()
                                        increasewarn=warninfo.getincrease_warn()
                                        console.log(superhighwarn)
                                        g1SO2.open()
                                        console.debug(gas)
                                    }
                                }
                            }
                            Rectangle {
                                id: b2
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: b1.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "NO"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="NO"
                                        database_gas="NO"
                                        warninfo.selectWarnInfobyName(database_gas)
                                        superhighwarn=warninfo.getsuperhigh_warn()
                                        highwarn=warninfo.gethigh_warn();
                                        lowwarn=warninfo.getlow_warn();
                                        superlowwarn=warninfo.getsuperlow_warn()
                                        deadwarn=warninfo.getdead_zone();
                                        declinewarn=warninfo.getdecline_warn()
                                        increasewarn=warninfo.getincrease_warn()
                                        g1SO2.open()
                                    }
                                }
                            }
                            Rectangle {
                                id: b3
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: b2.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "CO"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="CO"
                                        database_gas="CO"
                                        warninfo.selectWarnInfobyName(database_gas)
                                        superhighwarn=warninfo.getsuperhigh_warn()
                                        highwarn=warninfo.gethigh_warn();
                                        lowwarn=warninfo.getlow_warn();
                                        superlowwarn=warninfo.getsuperlow_warn()
                                        deadwarn=warninfo.getdead_zone();
                                        declinewarn=warninfo.getdecline_warn()
                                        increasewarn=warninfo.getincrease_warn()
                                        g1SO2.open()
                                    }
                                }
                            }
                            Rectangle {
                                id: b4
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: b3.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "O2"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="O2"
                                        database_gas="O2"
                                        warninfo.selectWarnInfobyName(database_gas)
                                        superhighwarn=warninfo.getsuperhigh_warn()
                                        highwarn=warninfo.gethigh_warn();
                                        lowwarn=warninfo.getlow_warn();
                                        superlowwarn=warninfo.getsuperlow_warn()
                                        deadwarn=warninfo.getdead_zone();
                                        declinewarn=warninfo.getdecline_warn()
                                        increasewarn=warninfo.getincrease_warn()
                                        g1SO2.open()
                                    }
                                }
                            }
                            Rectangle {
                                id: b5
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: b4.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "颗粒物"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="颗粒物"
                                        database_gas="particulate"
                                        warninfo.selectWarnInfobyName(database_gas)
                                        superhighwarn=warninfo.getsuperhigh_warn()
                                        highwarn=warninfo.gethigh_warn();
                                        lowwarn=warninfo.getlow_warn();
                                        superlowwarn=warninfo.getsuperlow_warn()
                                        deadwarn=warninfo.getdead_zone();
                                        declinewarn=warninfo.getdecline_warn()
                                        increasewarn=warninfo.getincrease_warn()
                                        g1NO2.open()
                                    }
                                }
                            }
                            Rectangle {
                                id: b6
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: b5.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "差压"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="差压"
                                        database_gas="d_pressure"
                                        warninfo.selectWarnInfobyName(database_gas)
                                        superhighwarn=warninfo.getsuperhigh_warn()
                                        highwarn=warninfo.gethigh_warn();
                                        lowwarn=warninfo.getlow_warn();
                                        superlowwarn=warninfo.getsuperlow_warn()
                                        deadwarn=warninfo.getdead_zone();
                                        declinewarn=warninfo.getdecline_warn()
                                        increasewarn=warninfo.getincrease_warn()
                                        g1SO2.open()
                                    }
                                }
                            }
                            Rectangle {
                                id: b7
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: b6.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "烟气温度"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="烟气温度"
                                        database_gas="temperature"
                                        warninfo.selectWarnInfobyName(database_gas)
                                        superhighwarn=warninfo.getsuperhigh_warn()
                                        highwarn=warninfo.gethigh_warn();
                                        lowwarn=warninfo.getlow_warn();
                                        superlowwarn=warninfo.getsuperlow_warn()
                                        deadwarn=warninfo.getdead_zone();
                                        declinewarn=warninfo.getdecline_warn()
                                        increasewarn=warninfo.getincrease_warn()
                                        g1NO2.open()
                                    }
                                }
                            }
                            Rectangle {
                                id: b8
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: b7.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "烟气压力"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="烟气压力"
                                        database_gas="pressure"
                                        warninfo.selectWarnInfobyName(database_gas)
                                        superhighwarn=warninfo.getsuperhigh_warn()
                                        highwarn=warninfo.gethigh_warn();
                                        lowwarn=warninfo.getlow_warn();
                                        superlowwarn=warninfo.getsuperlow_warn()
                                        deadwarn=warninfo.getdead_zone();
                                        declinewarn=warninfo.getdecline_warn()
                                        increasewarn=warninfo.getincrease_warn()
                                        g1NO2.open()
                                    }
                                }
                            }
                            Rectangle {
                                id: b9
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: b8.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "湿度"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="湿度"
                                        database_gas="humidity"
                                        warninfo.selectWarnInfobyName(database_gas)
                                        superhighwarn=warninfo.getsuperhigh_warn()
                                        highwarn=warninfo.gethigh_warn();
                                        lowwarn=warninfo.getlow_warn();
                                        superlowwarn=warninfo.getsuperlow_warn()
                                        deadwarn=warninfo.getdead_zone();
                                        declinewarn=warninfo.getdecline_warn()
                                        increasewarn=warninfo.getincrease_warn()
                                        g1SO2.open()
                                    }
                                }
                            }
                        }
                        Rectangle {
                            id: rec3101 //1#锅炉一列
                            height: parent.height - 2
                            width: 190
                            color: "cadetblue"
                            anchors.left: rec3100.right
                            anchors.leftMargin: 5
                            anchors.top: parent.top
                            anchors.topMargin: 1
                            Text {
                                id: t0
                                x: 55
                                y: 7
                                text: "1#锅炉"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "yellow"
                            }
                            Rectangle {
                                id: t1
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: t0.bottom
                                anchors.topMargin: 10
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: t2
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: t1.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: t3
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: t2.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: t4
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: t3.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: t5
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: t4.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: t6
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: t5.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: t7
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: t6.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text{
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: t8
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: t7.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: t9
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: t8.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text{
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                        }
                        Rectangle {
                            id: rec3102 //1#函数一列
                            height: parent.height - 2
                            width: 98
                            color: "cadetblue"
                            anchors.left: rec3101.right
                            anchors.leftMargin: 1
                            anchors.top: parent.top
                            anchors.topMargin: 1
                            Text {
                                id: b10
                                anchors.left: parent.left
                                anchors.top: parent.top
                                anchors.topMargin: 32
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                            Text {
                                id: b11
                                anchors.left: parent.left
                                anchors.top: b10.bottom
                                anchors.topMargin: 15
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                            Text {
                                id: b12
                                anchors.left: parent.left
                                anchors.top: b11.bottom
                                anchors.topMargin: 15
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                            Text {
                                id: b13
                                anchors.left: parent.left
                                anchors.top: b12.bottom
                                anchors.topMargin: 15
                                text: "%"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                            Text {
                                id: b14
                                anchors.left: parent.left
                                anchors.top: b13.bottom
                                anchors.topMargin: 15
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                            Text {
                                id: b15
                                anchors.left: parent.left
                                anchors.top: b14.bottom
                                anchors.topMargin: 15
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                            Text {
                                id: b16
                                anchors.left: parent.left
                                anchors.top: b15.bottom
                                anchors.topMargin: 15
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 14
                                color: "white"
                            }
                            Text {
                                id: b17
                                anchors.left: parent.left
                                anchors.top: b16.bottom
                                anchors.topMargin: 15
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 14
                                color: "white"
                            }
                            Text {
                                id: b18
                                anchors.left: parent.left
                                anchors.top: b17.bottom
                                anchors.topMargin: 14
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                        }
                    }
                    Rectangle {
                        id: rec311 //2#锅炉报警设定部分
                        width: 400
                        height: parent.height / 2
                        anchors.top: rec310.bottom
                        color: "cadetblue"
                        border.color: "black"
                        border.width: 1
                        Rectangle {
                            id: rec3110 //报警设定一列
                            height: parent.height - 2
                            width: 98
                            color: "cadetblue"
                            anchors.left: parent.left
                            anchors.leftMargin: 1
                            anchors.top: parent.top
                            anchors.topMargin: 1
                            Rectangle {
                                id: bj0
                                x: 20
                                y: 5
                                width: 80
                                height: 20
                                color: "cadetblue"
                                Text {
                                    text: "报警设定"
                                    color: "yellow"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    anchors.centerIn: parent
                                }
                            }
                            Rectangle {
                                id: bj1
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: bj0.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "SO2"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="SO2"
                                        g1SO2.open()
                                        console.debug(gas)
                                    }
                                }
                            }
                            Rectangle {
                                id: bj2
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: bj1.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "NO"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="NO"
                                        g1SO2.open()
                                        console.debug(gas)
                                    }
                                }
                            }
                            Rectangle {
                                id: bj3
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: bj2.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "CO"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="CO"
                                        g1SO2.open()
                                        console.debug(gas)
                                    }
                                }
                            }
                            Rectangle {
                                id: bj4
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: bj3.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "O2"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="O2"
                                        g1SO2.open()
                                        console.debug(gas)
                                    }
                                }
                            }
                            Rectangle {
                                id: bj5
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: bj4.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "颗粒物"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="颗粒物"
                                        g1NO2.open()

                                    }
                                }
                            }
                            Rectangle {
                                id: bj6
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: bj5.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "差压"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="差压"
                                        g1SO2.open()

                                    }
                                }
                            }
                            Rectangle {
                                id: bj7
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: bj6.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "烟气温度"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="烟气温度"
                                        g1NO2.open()

                                    }
                                }
                            }
                            Rectangle {
                                id: bj8
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: bj7.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "烟气压力"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="烟气压力"
                                        g1NO2.open()

                                    }
                                }
                            }
                            Rectangle {
                                id: bj9
                                x: 20
                                height: 20
                                width: 80
                                anchors.top: bj8.bottom
                                anchors.topMargin: 9
                                Button {
                                    width: parent.width
                                    height: parent.height
                                    text: "湿度"
                                    font.family: "Ubuntu"
                                    font.pixelSize: 15
                                    onClicked: {
                                        gas="温度"
                                        g1SO2.open()

                                    }
                                }
                            }
                        }
                        Rectangle {
                            id: rec3111 //2#锅炉一列
                            height: parent.height - 2
                            width: 190
                            color: "cadetblue"
                            anchors.left: rec3110.right
                            anchors.leftMargin: 5
                            anchors.top: parent.top
                            anchors.topMargin: 1
                            Text {
                                id: tj0
                                x: 55
                                y: 7
                                text: "2#锅炉"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "yellow"
                            }
                            Rectangle {
                                id: tj1
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: tj0.bottom
                                anchors.topMargin: 10
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: tj2
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: tj1.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: tj3
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: tj2.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: tj4
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: tj3.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: tj5
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: tj4.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: tj6
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: tj5.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: tj7
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: tj6.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: tj8
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: tj7.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                            Rectangle {
                                id: tj9
                                x: 25
                                height: 20
                                width: 150
                                anchors.top: tj8.bottom
                                anchors.topMargin: 9
                                border.color: "white"
                                Text {
                                    width: parent.width
                                    height: parent.height
                                }
                            }
                        }
                        Rectangle {
                            id: rec3112 //1#函数一列
                            height: parent.height - 2
                            width: 98
                            color: "cadetblue"
                            anchors.left: rec3111.right
                            anchors.leftMargin: 1
                            anchors.top: parent.top
                            anchors.topMargin: 1
                            Text {
                                id: bj10
                                anchors.left: parent.left
                                anchors.top: parent.top
                                anchors.topMargin: 32
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                            Text {
                                id: bj11
                                anchors.left: parent.left
                                anchors.top: bj10.bottom
                                anchors.topMargin: 15
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                            Text {
                                id: bj12
                                anchors.left: parent.left
                                anchors.top: bj11.bottom
                                anchors.topMargin: 15
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                            Text {
                                id: bj13
                                anchors.left: parent.left
                                anchors.top: bj12.bottom
                                anchors.topMargin: 15
                                text: "%"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                            Text {
                                id: bj14
                                anchors.left: parent.left
                                anchors.top: bj13.bottom
                                anchors.topMargin: 15
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                            Text {
                                id: bj15
                                anchors.left: parent.left
                                anchors.top: bj14.bottom
                                anchors.topMargin: 15
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                            Text {
                                id: bj16
                                anchors.left: parent.left
                                anchors.top: bj15.bottom
                                anchors.topMargin: 15
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 14
                                color: "white"
                            }
                            Text {
                                id: bj17
                                anchors.left: parent.left
                                anchors.top: bj16.bottom
                                anchors.topMargin: 15
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 14
                                color: "white"
                            }
                            Text {
                                id: bj18
                                anchors.left: parent.left
                                anchors.top: bj17.bottom
                                anchors.topMargin: 14
                                text: "mg/No3"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                        }
                    }
                }
                Rectangle {
                    id: rec32 //报警设定中间一列
                    width: 400
                    height: 675
                    border.color: "cadetblue"
                    anchors.left: rec31.right
                    anchors.leftMargin: 4
                    anchors.top: parent.top
                    anchors.topMargin: 6
                    Rectangle {
                        //标准气值设定
                        id: rec320
                        width: parent.width
                        height: parent.height / 3
                        border.color: "black"
                        color: "cadetblue"
                        Rectangle {
                            x: 1
                            y: 1
                            id: rec3201
                            height: 20
                            width: parent.width - 2
                            color: "cadetblue"
                            Text {
                                y: 2
                                text: "标准气值设定"
                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "yellow"
                            }
                        }
                        Rectangle {
                            id: bz11
                            width: 160
                            height: 20
                            anchors.top: rec3201.bottom
                            anchors.left: rec320.left
                            anchors.leftMargin: 15
                            anchors.topMargin: 5
                            border.color: "white"
                            color: "cadetblue"
                            Text {
                                text: "SO2标值"
                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                        }
                        Rectangle {
                            id: bz12
                            width: 90
                            height: 20
                            border.color: "white"
                            color: "cadetblue"
                            anchors.top: rec3201.bottom
                            anchors.topMargin: 5
                            anchors.left: bz11.right
                            anchors.leftMargin: 10
                            TextInput {
                                text: "2860"
                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                        }
                        Text {
                            id: bz13
                            anchors.left: bz12.right
                            anchors.leftMargin: 20
                            anchors.top: rec3201.bottom
                            anchors.topMargin: 5
                            text: qsTr("mg/NO2")
                            font.family: "Ubuntu"
                            font.pixelSize: 15
                            color: "white"
                        }
                        Rectangle {
                            id: bz21
                            width: 160
                            height: 20
                            anchors.top: bz11.bottom
                            anchors.left: rec320.left
                            anchors.leftMargin: 15
                            anchors.topMargin: 5
                            border.color: "white"
                            color: "cadetblue"
                            Text {
                                text: "SO2标值"
                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                        }
                        Rectangle {
                            id: bz22
                            width: 90
                            height: 20
                            border.color: "white"
                            color: "cadetblue"
                            anchors.top: bz12.bottom
                            anchors.topMargin: 5
                            anchors.left: bz11.right
                            anchors.leftMargin: 10
                            TextInput {
                                text: "2860"
                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                        }
                        Text {
                            id: bz23
                            anchors.left: bz12.right
                            anchors.leftMargin: 20
                            anchors.top: bz13.bottom
                            anchors.topMargin: 10
                            text: qsTr("mg/NO2")
                            font.family: "Ubuntu"
                            font.pixelSize: 15
                            color: "white"
                        }
                        Rectangle {
                            id: bz31
                            width: 160
                            height: 20
                            anchors.top: bz21.bottom
                            anchors.left: rec320.left
                            anchors.leftMargin: 15
                            anchors.topMargin: 5
                            border.color: "white"
                            color: "cadetblue"
                            Text {
                                text: "SO2标值"
                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                        }
                        Rectangle {
                            id: bz32
                            width: 90
                            height: 20
                            border.color: "white"
                            color: "cadetblue"
                            anchors.top: bz22.bottom
                            anchors.topMargin: 5
                            anchors.left: bz11.right
                            anchors.leftMargin: 10
                            TextInput {
                                text: "2860"
                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                        }
                        Text {
                            id: bz33
                            anchors.left: bz12.right
                            anchors.leftMargin: 20
                            anchors.top: bz23.bottom
                            anchors.topMargin: 8
                            text: qsTr("mg/NO2")
                            font.family: "Ubuntu"
                            font.pixelSize: 15
                            color: "white"
                        }
                        Rectangle {
                            id: bz41
                            width: 160
                            height: 20
                            anchors.top: bz31.bottom
                            anchors.left: rec320.left
                            anchors.leftMargin: 15
                            anchors.topMargin: 5
                            border.color: "white"
                            color: "cadetblue"
                            Text {
                                text: "SO2标值"
                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                        }
                        Rectangle {
                            id: bz42
                            width: 90
                            height: 20
                            border.color: "white"
                            color: "cadetblue"
                            anchors.top: bz32.bottom
                            anchors.topMargin: 5
                            anchors.left: bz41.right
                            anchors.leftMargin: 10
                            TextInput {
                                text: "2860"
                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                            }
                        }
                        Text {
                            id: bz43
                            anchors.left: bz42.right
                            anchors.leftMargin: 20
                            anchors.top: bz33.bottom
                            anchors.topMargin: 15
                            text: qsTr("mg/NO2")
                            font.family: "Ubuntu"
                            font.pixelSize: 15
                            color: "white"
                        }
                        Rectangle{
                            id:bz51
                            height:25
                            width: 110
                            color: "white"
                            anchors.left: parent.left
                            anchors.leftMargin: 15
                            anchors.top:bz41.bottom
                            anchors.topMargin: 10
                            Button{
                                height:parent.height
                                width:parent.width
                                text:"零点校准记录"
                                font.family: "Ubuntu"
                                font.pixelSize: 12
                                anchors.centerIn: parent
                            }
                        }
                        Rectangle{
                            id:bz52
                            height:25
                            width: 120
                            color: "white"
                            anchors.left: bz51.right
                            anchors.leftMargin: 5
                            anchors.top:bz41.bottom
                            anchors.topMargin: 10
                            Button{
                                height:parent.height
                                width:parent.width
                                text:"SO2量程校准记录"
                                font.family: "Ubuntu"
                                font.pixelSize: 12
                                anchors.centerIn: parent
                            }
                        }
                        Rectangle{
                            id:bz61
                            height:25
                            width: 110
                            color: "white"
                            anchors.left: parent.left
                            anchors.leftMargin: 15
                            anchors.top:bz51.bottom
                            anchors.topMargin: 10
                            Button{
                                height:parent.height
                                width:parent.width
                                text:"NO2量程校准记录"
                                font.family: "Ubuntu"
                                font.pixelSize: 12
                                anchors.centerIn: parent
                            }
                        }
                        Rectangle{
                            id:bz62
                            height:25
                            width: 120
                            color: "white"
                            anchors.left: bz61.right
                            anchors.leftMargin: 5
                            anchors.top:bz51.bottom
                            anchors.topMargin: 10
                            Button{
                                height:parent.height
                                width:parent.width
                                text:"CO量程校准记录"
                                font.family: "Ubuntu"
                                font.pixelSize: 12
                                anchors.centerIn: parent
                            }
                        }
                        Rectangle{
                            id:bz63
                            height:70
                            width: 120
                            border.color: "white"
                            color: "cadetblue"
                            anchors.top:bz42.bottom
                            anchors.topMargin: 10
                            anchors.left: bz52.right
                            anchors.leftMargin: 15
                            radius: 5

                            RadioButton {
                                id: bt4
                                anchors.top: parent.top
                                anchors.topMargin: 10
                                text: qsTr("gga")
                                checked: true

                                indicator: Rectangle {
                                    implicitWidth: 14
                                    implicitHeight: 14
                                    x: bt4.leftPadding
                                    y: parent.height / 2 - height / 2
                                    radius: 7
                                    border.color: bt4.down ? "#17a81a" : "#21be2b"

                                    Rectangle {
                                        width: 6
                                        height: 6
                                        x: 4
                                        y: 4
                                        radius: 3
                                        color: bt4.down ? "#17a81a" : "#21be2b"
                                        visible: bt4.checked
                                    }
                                }
                            }
                            RadioButton {
                                anchors.top: bt4.bottom
                                id: control31
                                text: qsTr("mg/NO3")

                                indicator: Rectangle {
                                    implicitWidth: 14
                                    implicitHeight: 14
                                    x: control31.leftPadding
                                    y: parent.height / 2 - height / 2
                                    radius: 7
                                    border.color: control31.down ? "#17a81a" : "#21be2b"

                                    Rectangle {
                                        width: 6
                                        height: 6
                                        x: 4
                                        y: 4
                                        radius: 3
                                        color: control31.down ? "#17a81a" : "#21be2b"
                                        visible: control31.checked
                                    }
                                }
                            }

                        }
                        Rectangle{
                            anchors.top: bz42.bottom
                            anchors.topMargin: 5
                            anchors.left: bz63.left
                            anchors.leftMargin: 5
                            height:15
                            width: 50
                            color: "cadetblue"
                            Text{

                                anchors.centerIn: parent
                                text:"单位选择"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "blue"

                            }
                        }

                    }
                    Rectangle {
                        id: rec321
                        width: parent.width
                        height: (parent.height / 9) * 2
                        border.color: "black"
                        anchors.top: rec320.bottom
                        color: "cadetblue"
                    }
                    Rectangle {
                        id: rec322
                        width: parent.width
                        height: parent.height / 9
                        border.color: "black"
                        anchors.top: rec321.bottom
                        color: "cadetblue"
                        Rectangle{
                            id:rec3220
                            width:100
                            height:20
                            x:5;y:30
                            color: "white"
                            Button {
                                text:"还原数据库"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                width:100
                                height:20
                                anchors.centerIn: parent
                                onClicked: databaseRest.open()
                            }
                        }
                        Rectangle{
                            //id:rec3220
                            width:120
                            height:20
                            x:110;y:30
                            color: "white"
                            Button {
                                text:"恢复出场设置"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                width:120
                                height:20
                                anchors.centerIn: parent
                                onClicked: initial.open()
                            }
                        }
                        Rectangle{
                            //id:rec3220
                            width:100
                            height:20
                            x:240;y:30
                            color: "white"
                            Button {
                                text:"系统功能"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                width:100
                                height:20
                                anchors.centerIn: parent
                                onClicked: {

                                    systemFunction.open()

                                }

                            }
                        }
                    }
                    Rectangle {
                        id: rec323
                        width: parent.width
                        height: parent.height / 3
                        border.color: "black"
                        anchors.top: rec322.bottom
                        color: "cadetblue"
                        Text{
                            id:rec3230
                            x:120;y:10
                            text:"用户信息设定"
                            color:"yellow"
                            font.family: "Ubuntu"
                            font.pixelSize: 20
                        }
                        Rectangle{

                            id:yh11
                            width:100
                            height:20
                            anchors.top: rec3230.bottom
                            anchors.topMargin: 15
                            anchors.left: parent.left
                            anchors.leftMargin: 15
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                width: parent.width
                                height:parent.height
                                text:"厂家名称"
                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 20
                                color: "white"
                            }
                        }
                        Rectangle{
                            id:yh12
                            width:150
                            height:20
                            anchors.top: rec3230.bottom
                            anchors.topMargin: 15
                            anchors.left: yh11.right
                            anchors.leftMargin: 15
                            color: "cadetblue"
                            border.color: "white"
                            TextInput{
                                width: parent.width
                                height:parent.height

                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 20
                                color: "white"
                            }
                        }
                        Rectangle{

                            id:yh21
                            width:100
                            height:20
                            anchors.top: yh11.bottom
                            anchors.topMargin: 15
                            anchors.left: parent.left
                            anchors.leftMargin: 15
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                width: parent.width
                                height:parent.height
                                text:"污染源A"
                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 20
                                color: "white"
                            }
                        }
                        Rectangle{
                            id:yh22
                            width:150
                            height:20
                            anchors.top: yh12.bottom
                            anchors.topMargin: 15
                            anchors.left: yh21.right
                            anchors.leftMargin: 15
                            color: "cadetblue"
                            border.color: "white"
                            TextInput{
                                width: parent.width
                                height:parent.height
                                text: "1#锅炉"
                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 20
                                color: "white"
                            }
                        }
                        Rectangle{

                            id:yh31
                            width:100
                            height:20
                            anchors.top: yh21.bottom
                            anchors.topMargin: 15
                            anchors.left: parent.left
                            anchors.leftMargin: 15
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                width: parent.width
                                height:parent.height
                                text:"污染源B"
                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 20
                                color: "white"
                            }
                        }
                        Rectangle{
                            id:yh32
                            width:150
                            height:20
                            anchors.top: yh22.bottom
                            anchors.topMargin: 15
                            anchors.left: yh31.right
                            anchors.leftMargin: 15
                            color: "cadetblue"
                            border.color: "white"
                            TextInput{
                                width: parent.width
                                height:parent.height
                                text: "2#锅炉"
                                anchors.centerIn: parent
                                font.family: "Ubuntu"
                                font.pixelSize: 20
                                color: "white"
                            }
                        }
                        Button{
                            width: 80
                            height: 25
                            text: "保存"
                            anchors.top:yh32.bottom
                            anchors.topMargin: 10
                            anchors.left: parent.left
                            anchors.leftMargin: 200
                            font.family: "Ubuntu"
                            font.pixelSize: 20
                            onClicked: {
                                gasflow.updateGasflow("1",pit1.text,vel1.text,sec1.text)
                                gasflow.updateGasflow("2",pit2.text,vel2.text,sec2.text)
                                particu.updateParticulate("1",dust_degreea1.text,dust_degreeb1.text,dust_degreec1.text)
                                particu.updateParticulate("2",dust_degreea2.text,dust_degreeb2.text,dust_degreec2.text)
                                otherpara.updateParameter(atomapress.text,atomapara.text)
                            }
                        }

                    }
                }
                Rectangle {
                    id: rec33 //报警设定右边一列
                    width: 400
                    height: 675
                    border.color: "black"
                    color: "cadetblue"
                    anchors.left: rec32.right
                    anchors.leftMargin: 4
                    anchors.top: parent.top
                    anchors.topMargin: 6
                    Rectangle {
                        id: rec330
                        width: parent.width
                        height: parent.height / 3
                        border.color: "black"
                        color: "cadetblue"
                        Text {
                            id: yq
                            x:100;y:2
                            text: "烟气流量参数设定"
                            font.family: "Ubuntu"
                            font.pixelSize: 15
                            color: "yellow"
                        }
                        Text {
                            id: yq1
                            x:15
                            text: "1#锅炉"
                            anchors.top: yq.bottom
                            anchors.topMargin: 2
                            font.family: "Ubuntu"
                            font.pixelSize: 15
                            color: "yellow"

                        }
                        Rectangle{
                            id:yq11
                            x:15;z:15
                            height:20
                            width: 160
                            anchors.top:yq1.bottom
                            anchors.topMargin: 2
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                text: "皮托管系数"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }


                        }
                        Rectangle{
                            id:yq12
                            height:20
                            width:120
                            anchors.top:yq1.bottom
                            anchors.topMargin: 2
                            anchors.left: yq11.right
                            anchors.leftMargin: 10
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                id:pit1
                                text: pitot1
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }
                            MouseArea{
                                anchors.fill: parent
                                cursorShape: Qt.OpenHandCursor

                                onClicked: {
                                    gas="皮托管"
                                    gas_flow="pitot_tube"
                                    guolu=1
                                    gasFlowset.open()
                                }
                            }
                        }
                        Rectangle{
                            id:yq21
                            x:15;z:15
                            height:20
                            width: 160
                            anchors.top:yq11.bottom
                            anchors.topMargin: 2
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                text: "速度场系数"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }

                        }
                        Rectangle{
                            id:yq22
                            height:20
                            width:120
                            anchors.top:yq12.bottom
                            anchors.topMargin: 2
                            anchors.left: yq21.right
                            anchors.leftMargin: 10
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                id:vel1
                                text: velocity1
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }
                            MouseArea{
                                anchors.fill: parent
                                cursorShape: Qt.OpenHandCursor

                                onClicked: {
                                    gas="速度场"
                                    gas_flow="velocity_field"
                                    guolu=1
                                    gasFlowset.open()
                                }
                            }
                        }
                        Rectangle{
                            id:yq31
                            x:15;z:15
                            height:20
                            width: 160
                            anchors.top:yq21.bottom
                            anchors.topMargin: 2
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                text: "烟道截面积"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }

                        }
                        Rectangle{
                            id:yq32
                            height:20
                            width:120
                            anchors.top:yq22.bottom
                            anchors.topMargin: 2
                            anchors.left: yq31.right
                            anchors.leftMargin: 10
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                id:sec1
                                text: sectional1
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }
                            MouseArea{
                                anchors.fill: parent
                                cursorShape: Qt.OpenHandCursor

                                onClicked: {
                                    gas="截面积"
                                    gas_flow="sectional_area"
                                    guolu=1
                                    gasFlowset.open()
                                }
                            }
                        }
                        Text{
                            anchors.left: yq32.right
                            anchors.leftMargin: 3
                            anchors.top:yq22.bottom
                            anchors.topMargin: 2
                            text: "m2"
                            font.family: "Ubuntu"
                            font.pixelSize: 15
                            color: "white"
                        }
                        Text {
                            id: yq2
                            x:15
                            text: "2#锅炉"
                            anchors.top: yq31.bottom
                            anchors.topMargin: 2
                            font.family: "Ubuntu"
                            font.pixelSize: 15
                            color: "yellow"

                        }
                        Rectangle{
                            id:yq41
                            x:15;z:15
                            height:20
                            width: 160
                            anchors.top:yq2.bottom
                            anchors.topMargin: 2
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                text: "皮托管系数"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }

                        }
                        Rectangle{
                            id:yq42
                            height:20
                            width:120
                            anchors.top:yq2.bottom
                            anchors.topMargin: 2
                            anchors.left: yq41.right
                            anchors.leftMargin: 10
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                id:pit2
                                text: pitot2
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }
                            MouseArea{
                                anchors.fill: parent
                                cursorShape: Qt.OpenHandCursor

                                onClicked: {
                                    gas="皮托管"
                                    guolu=2
                                    gasFlowset.open()
                                }
                            }
                        }
                        Rectangle{
                            id:yq51
                            x:15;z:15
                            height:20
                            width: 160
                            anchors.top:yq41.bottom
                            anchors.topMargin: 2
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                text: "速度场系数"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }

                        }
                        Rectangle{
                            id:yq52
                            height:20
                            width:120
                            anchors.top:yq42.bottom
                            anchors.topMargin: 2
                            anchors.left: yq51.right
                            anchors.leftMargin: 10
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                id:vel2
                                text: velocity2
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }
                            MouseArea{
                                anchors.fill: parent
                                cursorShape: Qt.OpenHandCursor

                                onClicked: {
                                    gas="速度场"
                                    guolu=2
                                    gasFlowset.open()
                                }
                            }
                        }
                        Rectangle{
                            id:yq61
                            x:15;z:15
                            height:20
                            width: 160
                            anchors.top:yq51.bottom
                            anchors.topMargin: 2
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                text: "烟道截面积"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }

                        }
                        Rectangle{
                            id:yq62
                            height:20
                            width:120
                            anchors.top:yq52.bottom
                            anchors.topMargin: 2
                            anchors.left: yq61.right
                            anchors.leftMargin: 10
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                id:sec2
                                text: sectional2
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }
                            MouseArea{
                                anchors.fill: parent
                                cursorShape: Qt.OpenHandCursor

                                onClicked: {
                                    gas="截面积"
                                    guolu=2
                                    gasFlowset.open()
                                }
                            }
                        }
                        Text{
                            anchors.left: yq62.right
                            anchors.leftMargin: 3
                            anchors.top:yq52.bottom
                            anchors.topMargin: 2
                            text: "m2"
                            font.family: "Ubuntu"
                            font.pixelSize: 15
                            color: "white"
                        }
                    }
                    Rectangle {
                        id: rec331
                        width: parent.width
                        height: parent.height / 2
                        border.color: "black"
                        color: "cadetblue"
                        anchors.top: rec330.bottom
                        Text {
                            id: kl
                            x:100;y:22
                            text: "颗粒物参数设定"
                            font.family: "Ubuntu"
                            font.pixelSize: 15
                            color: "yellow"
                        }
                        Text {
                            id: kl1
                            x:15
                            text: "1#锅炉"
                            anchors.top: kl.bottom
                            anchors.topMargin:22
                            font.family: "Ubuntu"
                            font.pixelSize: 15
                            color: "yellow"

                        }
                        Rectangle{
                            id:kl11
                            x:15;z:15
                            height:20
                            width: 160
                            anchors.top:kl1.bottom
                            anchors.topMargin: 2
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                text: "尘度系数A"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }

                        }
                        Rectangle{
                            id:kl12
                            height:20
                            width:120
                            anchors.top:kl1.bottom
                            anchors.topMargin: 2
                            anchors.left: kl11.right
                            anchors.leftMargin: 10
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                id:dust_degreea1
                                text: dusta1
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }
                            MouseArea{
                                anchors.fill: parent
                                onClicked: {
                                    guolu=1
                                    gas="尘度系数A"
                                    parti_name="dusta1"
                                    particulate.open()
                                }
                            }

                        }
                        Rectangle{
                            id:kl21
                            x:15;z:15
                            height:20
                            width: 160
                            anchors.top:kl11.bottom
                            anchors.topMargin: 2
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                text: "尘度系数B"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }

                        }
                        Rectangle{
                            id:kl22
                            height:20
                            width:120
                            anchors.top:kl12.bottom
                            anchors.topMargin: 2
                            anchors.left: kl21.right
                            anchors.leftMargin: 10
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                id:dust_degreeb1
                                text: dustb1
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }
                            MouseArea{
                                anchors.fill: parent
                                onClicked: {
                                    guolu=1
                                    gas="尘度系数B"
                                    parti_name="dustb1"
                                    particulate.open()
                                }
                            }
                        }
                        Rectangle{
                            id:kl31
                            x:15;z:15
                            height:20
                            width: 160
                            anchors.top:kl21.bottom
                            anchors.topMargin: 2
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                text: "尘度系数C"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }

                        }
                        Rectangle{
                            id:kl32
                            height:20
                            width:120
                            anchors.top:kl22.bottom
                            anchors.topMargin: 2
                            anchors.left: kl31.right
                            anchors.leftMargin: 10
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                id:dust_degreec1
                                text: dustc1
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }
                            MouseArea{
                                anchors.fill: parent
                                onClicked: {
                                    guolu=1
                                    gas="尘度系数C"
                                    parti_name="dustc1"
                                    particulate.open()
                                }
                            }
                        }

                        Text {
                            id: kl2
                            x:15
                            text: "2#锅炉"
                            anchors.top: kl31.bottom
                            anchors.topMargin: 50
                            font.family: "Ubuntu"
                            font.pixelSize: 15
                            color: "yellow"

                        }
                        Rectangle{
                            id:kl41
                            x:15;z:15
                            height:20
                            width: 160
                            anchors.top:kl2.bottom
                            anchors.topMargin: 2
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                text: "尘度系数A"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }

                        }
                        Rectangle{
                            id:kl42
                            height:20
                            width:120
                            anchors.top:kl2.bottom
                            anchors.topMargin: 2
                            anchors.left: kl41.right
                            anchors.leftMargin: 10
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                id:dust_degreea2
                                text: dusta2
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }
                            MouseArea{
                                anchors.fill: parent
                                onClicked: {
                                    guolu=2
                                    gas="尘度系数A"
                                    parti_name="dusta2"
                                    particulate.open()
                                }
                            }
                        }
                        Rectangle{
                            id:kl51
                            x:15;z:15
                            height:20
                            width: 160
                            anchors.top:kl41.bottom
                            anchors.topMargin: 2
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                text: "尘度系数B"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }

                        }
                        Rectangle{
                            id:kl52
                            height:20
                            width:120
                            anchors.top:kl42.bottom
                            anchors.topMargin: 2
                            anchors.left: kl51.right
                            anchors.leftMargin: 10
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                id:dust_degreeb2
                                text: dustb2
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }
                            MouseArea{
                                anchors.fill: parent
                                onClicked: {
                                    guolu=2
                                    gas="尘度系数B"
                                    parti_name="dustb2"
                                    particulate.open()
                                }
                            }
                        }
                        Rectangle{
                            id:kl61
                            x:15;z:15
                            height:20
                            width: 160
                            anchors.top:kl51.bottom
                            anchors.topMargin: 2
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                text: "尘度系数B"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }

                        }
                        Rectangle{
                            id:kl62
                            height:20
                            width:120
                            anchors.top:kl52.bottom
                            anchors.topMargin: 2
                            anchors.left: kl61.right
                            anchors.leftMargin: 10
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                id:dust_degreec2
                                text: dustc2
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }
                            MouseArea{
                                anchors.fill: parent
                                onClicked: {
                                    guolu=2
                                    gas="尘度系数C"
                                    parti_name="dustc2"
                                    particulate.open()
                                }
                            }
                        }

                    }
                    Rectangle {
                        id: rec332
                        width: parent.width
                        height: parent.height / 6
                        border.color: "black"
                        color: "cadetblue"
                        anchors.top: rec331.bottom
                        Text {
                            id: qt
                            x:100;y:2
                            text: "其它参数设定"
                            font.family: "Ubuntu"
                            font.pixelSize: 15
                            color: "yellow"
                        }
                        Rectangle{
                            id:qt11
                            x:15;z:15
                            height:20
                            width: 160
                            anchors.top:qt.bottom
                            anchors.topMargin: 5
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                text: "大气压力"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }

                        }
                        Rectangle{
                            id:qt12
                            height:20
                            width:120
                            anchors.top:qt.bottom
                            anchors.topMargin: 5
                            anchors.left: qt11.right
                            anchors.leftMargin: 10
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                id:atomapress
                                text: atmos_press
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }
                            MouseArea{
                                anchors.fill: parent
                                onClicked: {
                                    gas="大气压力"
                                    parti_name="atmospress"
                                    atmospara.open()
                                }
                            }
                        }
                        Text{
                            anchors.left: qt12.right
                            anchors.leftMargin: 3
                            anchors.top:qt.bottom
                            anchors.topMargin: 5
                            text: "Pa"
                            font.family: "Ubuntu"
                            font.pixelSize: 15
                            color: "white"
                        }
                        Rectangle{
                            id:qt21
                            x:15;z:15
                            height:20
                            width: 160
                            anchors.top:qt11.bottom
                            anchors.topMargin: 5
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                text: "标准过量空气系数"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }

                        }
                        Rectangle{
                            id:qt22
                            height:20
                            width:120
                            anchors.top:qt12.bottom
                            anchors.topMargin: 5
                            anchors.left: qt21.right
                            anchors.leftMargin: 10
                            color: "cadetblue"
                            border.color: "white"
                            Text{
                                id:atomapara
                                text: atmos_para
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                                color: "white"
                                anchors.centerIn: parent
                            }
                            MouseArea{
                                anchors.fill: parent
                                onClicked: {
                                    gas="空气系数"
                                    parti_name="atmospara"
                                    atmospara.open()
                                }
                            }
                        }
                    }
                }
            }
  Popup{
                id:systemFunction
                width:1280
                height:800
                topPadding: 0
                leftPadding: 0
                rightPadding: 0
                bottomPadding: 0
                Rectangle{
                    width: 1280
                    height: 800
                    color:"cadetblue";
                    Rectangle {
                        x: 15
                        y: 10
                        height: 50
                        width: 130
                        color: "cadetblue"
                        border.color: "black"
                        border.width: 2
                        Text {
                            text: "系统功能"
                            color: "yellow"
                            anchors.centerIn: parent
                            font.family: "Ubuntu"
                            font.pixelSize: 25
                        }
                        Image {
                            id: back
                            x: 1150
                            width: 50
                            height: 50
                            source: "qrc:///images/right.png"

                        }
//                        Button{
//                            width: 70
//                            height: 25
//                            x:1200;y:15
//                            text:"返回"
//                            onClicked: {
//                                systemFunction.close()
//                            }
//                        }
                        Rectangle{
                            width: 50
                            height:25
                            x: 1220
                            y: 15
                            z:2//必须不然mousearea会覆盖无法识别
                            color: "cadetblue"
                            Text {

                                text: "返回"
                                color: "black"
                                font.family: "Ubuntu"
                                font.pixelSize: 20
                            }
                            MouseArea{
                                 anchors.fill: parent

                                 onClicked: {
                                     systemFunction.close()
                                 }
                            }



                        }

                        Rectangle {
                            x: 1000
                            y: 50
                            width: 200
                            height: 30
                            color: "black"
                            Timer {
                                interval: 500; running: true; repeat: true
                                onTriggered: systemtimeview.text = Qt.formatDateTime(new Date(),
                                                        "yyyy-MM-dd hh:mm:ss")
                            }
                            Text {
                                id:systemtimeview
                                anchors.centerIn: parent
                                color: "yellow"
                                font.family: "Ubuntu"
                                font.pixelSize: 15
                            }
                        }
                        Rectangle {
                            x: 1
                            y: 90
                            width: 1200
                            height: 680
                            color: "cadetblue"
                            border.color: "black"
                            border.width: 2
                            Rectangle {
                                id: recxt
                                width: 700
                                height: parent.height
                                color: "cadetblue"
                                border.color: "black"
                                border.width: 1
                                Rectangle {
                                    id: xt1
                                    width: parent.width
                                    height: 140
                                    anchors.top: parent.top
                                    color: "cadetblue"
                                    border.color: "black"
                                    Rectangle {
                                        x: 240
                                        y: 10
                                        width: 150
                                        height: 25
                                        color: "#1E90FF"
                                        border.color: "black"
                                        Text {
                                            text: "系统状态监视"
                                            anchors.centerIn: parent
                                            color: "yellow"
                                            font.family: "Ubuntu"
                                            font.pixelSize: 15
                                        }
                                    }
                                    Rectangle {
                                        x: 10
                                        y: 55
                                        width: 140
                                        height: 30
                                        color: "white"
                                        Button {
                                            width: 140
                                            height: 30
                                            text: "监视通信驱动(Modbus)"
                                            anchors.centerIn: parent
                                            font.family: "Ubuntu"
                                            font.pixelSize: 12
                                        }
                                    }
                                    Rectangle {
                                        x: 155
                                        y: 55
                                        width: 125
                                        height: 30
                                        color: "white"
                                        Button {
                                            width: 125
                                            height: 30
                                            text: "监视通信驱动(PPI)"
                                            anchors.centerIn: parent
                                            font.family: "Ubuntu"
                                            font.pixelSize: 12
                                        }
                                    }
                                    Rectangle {
                                        x: 285
                                        y: 55
                                        width: 125
                                        height: 30
                                        color: "white"
                                        Button {
                                            width: 125
                                            height: 30
                                            text: "监视运行数据库"
                                            anchors.centerIn: parent
                                            font.family: "Ubuntu"
                                            font.pixelSize: 12
                                        }
                                    }
                                    Rectangle {
                                        x: 415
                                        y: 55
                                        width: 140
                                        height: 30
                                        color: "white"
                                        Button {
                                            width: 140
                                            height: 30
                                            text: "查看数据库连接状态"
                                            anchors.centerIn: parent
                                            font.family: "Ubuntu"
                                            font.pixelSize: 12
                                        }
                                    }
                                    Rectangle {
                                        x: 560
                                        y: 55
                                        width: 130
                                        height: 30
                                        color: "white"
                                        Button {
                                            width: 130
                                            height: 30
                                            text: "监视设备数据表"
                                            anchors.centerIn: parent
                                            font.family: "Ubuntu"
                                            font.pixelSize: 12
                                        }
                                    }
                                }
                                Rectangle {
                                    id: xt2
                                    width: parent.width
                                    height: 240
                                    anchors.top: xt1.bottom
                                    color: "cadetblue"
                                    border.color: "black"
                                    Rectangle {
                                        x: 240
                                        y: 30
                                        width: 150
                                        height: 25
                                        color: "#1E90FF"
                                        border.color: "black"
                                        Text {
                                            text: "系统功能"
                                            anchors.centerIn: parent
                                            color: "yellow"
                                            font.family: "Ubuntu"
                                            font.pixelSize: 15
                                        }
                                    }
                                    Rectangle {
                                        x: 10
                                        y: 75
                                        width: 140
                                        height: 30
                                        color: "white"
                                        Button {
                                            width: 140
                                            height: 30
                                            text: "系统驱动设置"
                                            anchors.centerIn: parent
                                            font.family: "Ubuntu"
                                            font.pixelSize: 12
                                        }
                                    }
                                    Rectangle {
                                        x: 155
                                        y: 75
                                        width: 125
                                        height: 30
                                        color: "white"
                                        Button {
                                            width: 125
                                            height: 30
                                            text: "项目备份"
                                            anchors.centerIn: parent
                                            font.family: "Ubuntu"
                                            font.pixelSize: 12
                                        }
                                    }
//                                    Rectangle {
//                                        x: 285
//                                        y: 75
//                                        width: 125
//                                        height: 30
//                                        color: "white"
//                                        Button {
//                                            width: 125
//                                            height: 30
//                                            text: "数据补齐"
//                                            anchors.centerIn: parent
//                                            font.family: "Ubuntu"
//                                            font.pixelSize: 12
//                                        }
//                                    }
                                    Rectangle {
                                        x: 285
                                        y: 75
                                        width: 140
                                        height: 30
                                        color: "white"
                                        Button {
                                            width: 140
                                            height: 30
                                            text: "监控系统重启"
                                            anchors.centerIn: parent
                                            font.family: "Ubuntu"
                                            font.pixelSize: 12

                                        }
                                    }
                                    Rectangle {
                                        x: 430
                                        y: 75
                                        width: 130
                                        height: 30
                                        color: "white"
                                        Button {
                                            width: 130
                                            height: 30
                                            text: "WINDOWS重启"
                                            anchors.centerIn: parent
                                            font.family: "Ubuntu"
                                            font.pixelSize: 12
                                        }
                                    }
                                    Rectangle {
                                        x: 10
                                        y: 130
                                        width: 140
                                        height: 30
                                        color: "white"
                                        Button {
                                            width: 140
                                            height: 30
                                            text: "SDLTransmit"
                                            anchors.centerIn: parent
                                            font.family: "Ubuntu"
                                            font.pixelSize: 12
                                        }
                                    }
                                    Rectangle {
                                        x: 155
                                        y: 130
                                        width: 125
                                        height: 30
                                        color: "white"
                                        Button {
                                            width: 125
                                            height: 30
                                            text: "SDLTransmit(二)"
                                            anchors.centerIn: parent
                                            font.family: "Ubuntu"
                                            font.pixelSize: 12
                                        }
                                    }
//                                    Rectangle {
//                                        x: 285
//                                        y: 130
//                                        width: 125
//                                        height: 30
//                                        color: "white"
//                                        Button {
//                                            width: 125
//                                            height: 30
//                                            text: "SDLTransmit"
//                                            anchors.centerIn: parent
//                                            font.family: "Ubuntu"
//                                            font.pixelSize: 12
//                                        }
//                                    }
//                                    Rectangle {
//                                        x: 415
//                                        y: 130
//                                        width: 140
//                                        height: 30
//                                        color: "white"
//                                        Button {
//                                            width: 140
//                                            height: 30
//                                            text: "SDLTransmit(二)"
//                                            anchors.centerIn: parent
//                                            font.family: "Ubuntu"
//                                            font.pixelSize: 12
//                                        }
//                                    }
                                }
                                Rectangle {
                                    id: xt3
                                    width: parent.width
                                    height: 80
                                    anchors.top: xt2.bottom
                                    color: "cadetblue"
                                    border.color: "black"
                                }
                                Rectangle {
                                    id: xt4
                                    width: parent.width
                                    height: 220
                                    anchors.top: xt3.bottom
                                    color: "cadetblue"
                                    border.color: "black"
                                    Rectangle {
                                        x: 10
                                        y: 140
                                        height: 30
                                        width: 120
                                        color: "white"
                                        Button {
                                            width: parent.width
                                            height: parent.height
                                            text: "串口调试器"
                                            anchors.centerIn: parent
                                            font.family: "Ubuntu"
                                            font.pixelSize: 15
                                        }
                                    }
                                    Rectangle {
                                        x: 140
                                        y: 140
                                        height: 30
                                        width: 120
                                        color: "white"
                                        Button {
                                            width: parent.width
                                            height: parent.height
                                            text: "输出系统信息"
                                            anchors.centerIn: parent
                                            font.family: "Ubuntu"
                                            font.pixelSize: 15
                                            onClicked: {
                                                console.log()
                                            }
                                        }
                                    }
//                                    Rectangle {
//                                        x: 270
//                                        y: 140
//                                        height: 30
//                                        width: 120
//                                        color: "white"
//                                        Button {
//                                            width: parent.width
//                                            height: parent.height
//                                            text: "打开记事本"
//                                            anchors.centerIn: parent
//                                            font.family: "Ubuntu"
//                                            font.pixelSize: 15
//                                        }
//                                    }
//                                    Rectangle {
//                                        x: 400
//                                        y: 140
//                                        height: 30
//                                        width: 130
//                                        color: "white"
//                                        Button {
//                                            width: parent.width
//                                            height: parent.height
//                                            text: "输出系统信息"
//                                            anchors.centerIn: parent
//                                            font.family: "Ubuntu"
//                                            font.pixelSize: 15
//                                        }
//                                    }
//                                    Rectangle {
//                                        x: 540
//                                        y: 140
//                                        height: 30
//                                        width: 120
//                                        color: "white"
//                                        Button {
//                                            width: parent.width
//                                            height: parent.height
//                                            text: "打开记事本"
//                                            anchors.centerIn: parent
//                                            font.family: "Ubuntu"
//                                            font.pixelSize: 15
//                                        }
//                                    }
                                }
                            }
                            Rectangle {
                                id: recsj
                                width: 500
                                height: parent.height
                                anchors.left: recxt.right
                                color: "cadetblue"
                                border.color: "black"
                                border.width: 1
                                Rectangle {
                                    id: sj1
                                    width: parent.width
                                    height: 250
                                    color: "cadetblue"
                                    border.color: "black"
                                    Rectangle {
                                        x: 210
                                        y: 10
                                        width: 225
                                        height: 30
                                        color: "#1E90FF"
                                        Text {
                                            text: "数据库连接状态"
                                            anchors.centerIn: parent
                                            font.family: "Ubuntu"
                                            font.pixelSize: 20
                                            color: "yellow"
                                        }
                                    }

                                    Text {
                                        x: 10
                                        y: 50
                                        text: "分钟数据A连接状态"
                                        width: 200
                                        height: 30
                                        font.family: "Ubuntu"
                                        font.pixelSize: 20
                                        color: "yellow"
                                    }
                                    Rectangle {
                                        x: 210
                                        y: 45
                                        width: 225
                                        height: 30
                                        color: "cadetblue"
                                        border.color: "white"
                                        Text {

                                            text: "正常"
                                            font.family: "Ubuntu"
                                            font.pixelSize: 20
                                            color: "black"
                                            anchors.centerIn: parent
                                        }
                                    }
                                    Text {
                                        x: 10
                                        y: 95
                                        text: "分钟数据B连接状态"
                                        width: 200
                                        height: 30
                                        font.family: "Ubuntu"
                                        font.pixelSize: 20
                                        color: "yellow"
                                    }
                                    Rectangle {
                                        x: 210
                                        y: 85
                                        width: 225
                                        height: 30
                                        color: "cadetblue"
                                        border.color: "white"
                                        Text {

                                            text: "正常"
                                            font.family: "Ubuntu"
                                            font.pixelSize: 20
                                            color: "black"
                                            anchors.centerIn: parent
                                        }
                                    }
                                    Text {
                                        x: 10
                                        y: 135
                                        text: "用户参数A连接状态"
                                        width: 200
                                        height: 30
                                        font.family: "Ubuntu"
                                        font.pixelSize: 20
                                        color: "yellow"
                                    }
                                    Rectangle {
                                        x: 210
                                        y: 125
                                        width: 225
                                        height: 30
                                        color: "cadetblue"
                                        border.color: "white"
                                        Text {

                                            text: "正常"
                                            font.family: "Ubuntu"
                                            font.pixelSize: 20
                                            color: "black"
                                            anchors.centerIn: parent
                                        }
                                    }
                                    Text {
                                        x: 10
                                        y: 165
                                        text: "用户参数B连接状态"
                                        width: 200
                                        height: 30
                                        font.family: "Ubuntu"
                                        font.pixelSize: 20
                                        color: "yellow"
                                    }
                                    Rectangle {
                                        x: 210
                                        y: 160
                                        width: 225
                                        height: 30
                                        color: "cadetblue"
                                        border.color: "white"
                                        Text {

                                            text: "正常"
                                            font.family: "Ubuntu"
                                            font.pixelSize: 20
                                            color: "black"
                                            anchors.centerIn: parent
                                        }
                                    }
                                }
                                Rectangle {
                                    id: sj2
                                    width: parent.width
                                    height: 150
                                    color: "cadetblue"
                                    border.color: "black"
                                    anchors.top: sj1.bottom
                                    Text {
                                        y: 2
                                        anchors.horizontalCenter: parent.horizontalCenter
                                        text: "仪表单位设定"
                                        font.family: "Ubuntu"
                                        font.pixelSize: 17
                                        color: "yellow"
                                    }
                                    Text {
                                        x: 60
                                        y: 20

                                        text: "1#锅炉"
                                        font.family: "Ubuntu"
                                        font.pixelSize: 15
                                        color: "yellow"
                                    }
                                    Text {
                                        x: 350
                                        y: 20

                                        text: "2#锅炉"
                                        font.family: "Ubuntu"
                                        font.pixelSize: 15
                                        color: "yellow"
                                    }
                                    Rectangle {
                                        x: 60
                                        y: 45
                                        radius: 5
                                        height: 80
                                        width: 110
                                        border.color: "white"
                                        color: "cadetblue"

                                        RadioButton {
                                            id: bt1
                                            anchors.top: parent.top
                                            anchors.topMargin: 15
                                            text: qsTr("mg/NO2")
                                            checked: true

                                            indicator: Rectangle {
                                                implicitWidth: 14
                                                implicitHeight: 14
                                                x: bt1.leftPadding
                                                y: parent.height / 2 - height / 2
                                                radius: 7
                                                border.color: bt1.down ? "#17a81a" : "#21be2b"

                                                Rectangle {
                                                    width: 6
                                                    height: 6
                                                    x: 4
                                                    y: 4
                                                    radius: 3
                                                    color: bt1.down ? "#17a81a" : "#21be2b"
                                                    visible: bt1.checked
                                                }
                                            }
                                        }
                                        RadioButton {
                                            anchors.top: bt1.bottom
                                            id: control
                                            text: qsTr("PQ%")

                                            indicator: Rectangle {
                                                implicitWidth: 14
                                                implicitHeight: 14
                                                x: control.leftPadding
                                                y: parent.height / 2 - height / 2
                                                radius: 7
                                                border.color: control.down ? "#17a81a" : "#21be2b"

                                                Rectangle {
                                                    width: 6
                                                    height: 6
                                                    x: 4
                                                    y: 4
                                                    radius: 3
                                                    color: control.down ? "#17a81a" : "#21be2b"
                                                    visible: control.checked
                                                }
                                            }
                                        }
                                    }
                                    Rectangle {
                                        x: 65
                                        y: 40
                                        width: 57
                                        height: 20
                                        color: "cadetblue"
                                        Text {

                                            text: "仪表单位"
                                            font.family: "Ubuntu"
                                            font.pixelSize: 15
                                            color: "yellow"
                                        }

                                        }
                                    Rectangle {
                                        x: 350
                                        y: 45
                                        radius: 5
                                        height: 80
                                        width: 110
                                        border.color: "white"
                                        color: "cadetblue"

                                        RadioButton {
                                            id: bt2
                                            anchors.top: parent.top
                                            anchors.topMargin: 15
                                            text: qsTr("mg/NO2")
                                            checked: true

                                            indicator: Rectangle {
                                                implicitWidth: 14
                                                implicitHeight: 14
                                                x: bt2.leftPadding
                                                y: parent.height / 2 - height / 2
                                                radius: 7
                                                border.color: bt2.down ? "#17a81a" : "#21be2b"

                                                Rectangle {
                                                    width: 6
                                                    height: 6
                                                    x: 4
                                                    y: 4
                                                    radius: 3
                                                    color: bt2.down ? "#17a81a" : "#21be2b"
                                                    visible: bt2.checked
                                                }
                                            }
                                        }
                                        RadioButton {
                                            anchors.top: bt2.bottom
                                            id: control1
                                            text: qsTr("PQ%")

                                            indicator: Rectangle {
                                                implicitWidth: 14
                                                implicitHeight: 14
                                                x: control1.leftPadding
                                                y: parent.height / 2 - height / 2
                                                radius: 7
                                                border.color: control1.down ? "#17a81a" : "#21be2b"

                                                Rectangle {
                                                    width: 6
                                                    height: 6
                                                    x: 4
                                                    y: 4
                                                    radius: 3
                                                    color: control1.down ? "#17a81a" : "#21be2b"
                                                    visible: control1.checked
                                                }
                                            }
                                        }
                                    }
                                    Rectangle {
                                        x: 355
                                        y: 40
                                        width: 57
                                        height: 20
                                        color: "cadetblue"
                                        Text {

                                            text: "仪表单位"
                                            font.family: "Ubuntu"
                                            font.pixelSize: 15
                                            color: "yellow"
                                        }

                                        }
                                }
                                Rectangle{
                                    id:sj3
                                    width: parent.width
                                    height: 250
                                    anchors.top: sj2.bottom
                                    border.color: "black"
                                    color:"cadetblue"
                                    Text {
                                        y: 2
                                        anchors.horizontalCenter: parent.horizontalCenter
                                        text: "烟气湿度参数设定"
                                        font.family: "Ubuntu"
                                        font.pixelSize: 17
                                        color: "yellow"
                                    }
                                    Text {
                                        x: 60
                                        y: 20

                                        text: "1#锅炉"
                                        font.family: "Ubuntu"
                                        font.pixelSize: 15
                                        color: "yellow"
                                    }
                                    Text {
                                        x: 350
                                        y: 20

                                        text: "2#锅炉"
                                        font.family: "Ubuntu"
                                        font.pixelSize: 15
                                        color: "yellow"
                                    }
                                    Rectangle {
                                        x: 60
                                        y: 45
                                        radius: 5
                                        height: 120
                                        width: 120
                                        border.color: "white"
                                        color: "cadetblue"

                                        RadioButton {
                                            id: bt3
                                            anchors.top: parent.top
                                            anchors.topMargin: 15
                                            text: qsTr("干湿氧计算")
                                            checked: true

                                            indicator: Rectangle {
                                                implicitWidth: 14
                                                implicitHeight: 14
                                                x: bt3.leftPadding
                                                y: parent.height / 2 - height / 2
                                                radius: 7
                                                border.color: bt3.down ? "#17a81a" : "#21be2b"

                                                Rectangle {
                                                    width: 6
                                                    height: 6
                                                    x: 4
                                                    y: 4
                                                    radius: 3
                                                    color: bt3.down ? "#17a81a" : "#21be2b"
                                                    visible: bt3.checked
                                                }
                                            }
                                        }
                                        RadioButton {
                                            anchors.top: bt3.bottom
                                            id: control2
                                            text: qsTr("手工设定")

                                            indicator: Rectangle {
                                                implicitWidth: 14
                                                implicitHeight: 14
                                                x: control2.leftPadding
                                                y: parent.height / 2 - height / 2
                                                radius: 7
                                                border.color: control2.down ? "#17a81a" : "#21be2b"

                                                Rectangle {
                                                    width: 6
                                                    height: 6
                                                    x: 4
                                                    y: 4
                                                    radius: 3
                                                    color: control2.down ? "#17a81a" : "#21be2b"
                                                    visible: control2.checked
                                                }
                                            }
                                        }
                                        RadioButton {
                                            anchors.top: control2.bottom
                                            id: control4
                                            text: qsTr("直接测量")

                                            indicator: Rectangle {
                                                implicitWidth: 14
                                                implicitHeight: 14
                                                x: control4.leftPadding
                                                y: parent.height / 2 - height / 2
                                                radius: 7
                                                border.color: control4.down ? "#17a81a" : "#21be2b"

                                                Rectangle {
                                                    width: 6
                                                    height: 6
                                                    x: 4
                                                    y: 4
                                                    radius: 3
                                                    color: control4.down ? "#17a81a" : "#21be2b"
                                                    visible: control4.checked
                                                }
                                            }
                                        }
                                    }
                                    Rectangle {
                                        x: 65
                                        y: 40
                                        width: 65
                                        height: 20
                                        color: "cadetblue"
                                        Text {

                                            text: "湿度选择值"
                                            font.family: "Ubuntu"
                                            font.pixelSize: 15
                                            color: "yellow"
                                        }

                                        }
                                    Rectangle {
                                        x: 350
                                        y: 45
                                        radius: 5
                                        height: 120
                                        width: 120
                                        border.color: "white"
                                        color: "cadetblue"

                                        RadioButton {
                                            id: gsy2
                                            anchors.top: parent.top
                                            anchors.topMargin: 15
                                            text: qsTr("干湿氧计算")
                                            checked: true

                                            indicator: Rectangle {
                                                implicitWidth: 14
                                                implicitHeight: 14
                                                x:gsy2.leftPadding
                                                y: parent.height / 2 - height / 2
                                                radius: 7
                                                border.color: gsy2.down ? "#17a81a" : "#21be2b"

                                                Rectangle {
                                                    width: 6
                                                    height: 6
                                                    x: 4
                                                    y: 4
                                                    radius: 3
                                                    color: gsy2.down ? "#17a81a" : "#21be2b"
                                                    visible:gsy2.checked
                                                }
                                            }
                                        }
                                        RadioButton {
                                            anchors.top: gsy2.bottom
                                            id: sg2
                                            text: qsTr("手工设定")

                                            indicator: Rectangle {
                                                implicitWidth: 14
                                                implicitHeight: 14
                                                x: sg2.leftPadding
                                                y: parent.height / 2 - height / 2
                                                radius: 7
                                                border.color: sg2.down ? "#17a81a" : "#21be2b"

                                                Rectangle {
                                                    width: 6
                                                    height: 6
                                                    x: 4
                                                    y: 4
                                                    radius: 3
                                                    color: sg2.down ? "#17a81a" : "#21be2b"
                                                    visible: sg2.checked
                                                }
                                            }
                                        }
                                        RadioButton {
                                            anchors.top: sg2.bottom
                                            id: measure
                                            text: qsTr("直接测量")

                                            indicator: Rectangle {
                                                implicitWidth: 14
                                                implicitHeight: 14
                                                x: measure.leftPadding
                                                y: parent.height / 2 - height / 2
                                                radius: 7
                                                border.color: measure.down ? "#17a81a" : "#21be2b"

                                                Rectangle {
                                                    width: 6
                                                    height: 6
                                                    x: 4
                                                    y: 4
                                                    radius: 3
                                                    color: measure.down ? "#17a81a" : "#21be2b"
                                                    visible: measure.checked
                                                }
                                            }
                                        }
                                    }
                                    Rectangle {
                                        x: 355
                                        y: 40
                                        width: 65
                                        height: 20
                                        color: "cadetblue"
                                        Text {

                                            text: "湿度选择值"
                                            font.family: "Ubuntu"
                                            font.pixelSize: 15
                                            color: "yellow"
                                        }

                                        }

                                }
                            }
                        }
                    }

                    //    MainForm {
                    //        anchors.fill: parent
                    //        mouseArea.onClicked: {
                    //            Qt.quit();
                    //        }
                    //    }
                }

            }
  Popup{
      id: g1SO2
      width: 1280
      height: 800

//      x: (parent.width - width) / 2
//      y: (parent.height - height) / 2
//      topPadding: 0
//      leftPadding: 0
//      rightPadding: 0
//      bottomPadding: 0
      background: Rectangle {
          implicitWidth: 1280
          implicitHeight: 800
          color: "transparent"
          border.color: "#444"
      }
      modal: false
      focus: true


      closePolicy: Popup.CloseOnEscape | Popup.CloseOnPressOutsideParent
      Rectangle{

          width: 600
          height: 400
          x: (parent.width - width) / 2
          y: (parent.height - height) / 2
          Rectangle {//标题栏
              width: parent.width
              height: 50
              color: "#9cd9d8"
              Text {
                  x: 20
                  anchors.verticalCenter: parent.verticalCenter
                  text: "设置变量报警..."
                  color: "white"
              }
              Image {
                  id: close
                  y: 5
                  width: 40
                  height: 40
                  anchors.right: parent.right
                  source: "qrc:///images/close.png"
                  MouseArea {
                      anchors.fill: parent
                      acceptedButtons: Qt.LeftButton

                      onClicked: {
                         g1SO2.close()
                      }
                  }
              }
          }
          Rectangle{//内容栏
              y:50
              width: parent.width
              height: parent.height-50
              color: "white"
              Rectangle{//设置矩形框
                  x:20;y:30

                  width:parent.width-40
                  height:200
                  radius: 5
                  border.color: "gray"
                  border.width: 2

                  CheckBox {
                      x:20;y:20
                      text: "允许报警(根据变量值)"
                      font.family:"Ubuntu"
                      font.pixelSize:25
                      checked: true
                      enabled: false
                  }
                  Text{
                      id:d1so2b
                      x:35;y:70
                      text:"超高报警值:"
                      font.family:"Ubuntu"
                      font.pixelSize:25

                  }
                  Rectangle{

                      y:70
                      anchors.left: d1so2b.right
                      width:100
                      height:25
                      border.color: "gray"
                      TextInput{
                          id:superhigh
                          text:superhighwarn
                          anchors.fill: parent
                          maximumLength: 8
                      }
                  }
                  Text{
                      id:d1so2b1
                      x:60;y:100
                      text:"高报警值:"
                      font.family:"Ubuntu"
                      font.pixelSize:25

                  }
                  Rectangle{
                      y:100
                      anchors.left: d1so2b1.right
                      width:100
                      height:25
                      border.color: "gray"
                      TextInput{
                          id:high
                          text:highwarn
                          anchors.fill: parent
                          maximumLength: 8
                      }
                  }
                  Text{
                      id:d1so2b2
                      x:60;y:130
                      text:"低报警值:"
                      font.family:"Ubuntu"
                      font.pixelSize:25

                  }
                  Rectangle{
                      y:130
                      anchors.left: d1so2b2.right
                      width:100
                      height:25
                      border.color: "gray"
                      TextInput{
                          id:lower
                          text:lowwarn
                          anchors.fill: parent
                          maximumLength: 8
                      }
                  }
                  Text{
                      id:d1so2b3
                      x:35;y:160
                      text:"超低报警值:"
                      font.family:"Ubuntu"
                      font.pixelSize:25

                  }
                  Rectangle{
                      y:160
                      anchors.left: d1so2b3.right
                      width:100
                      height:25
                      border.color: "gray"
                      TextInput{
                          id:superlower
                          text:superlowwarn
                          anchors.fill: parent
                          maximumLength: 8
                      }
                  }
                  Text{
                      id:d1so2b4
                      x:325;y:85
                      text:"死区(%):"
                      font.family:"Ubuntu"
                      font.pixelSize:25

                  }
                  Rectangle{
                      y:85
                      width:100
                      height:25
                      anchors.left: d1so2b4.right
                      border.color: "gray"
                      TextInput{
                          id:dead
                          text:deadwarn
                          anchors.fill: parent
                          maximumLength: 8
                      }
                  }
                  Text{
                      id:d1so2b5
                      x:290;y:130
                      text:"降幅报警值:"
                      font.family:"Ubuntu"
                      font.pixelSize:25

                  }
                  Rectangle{
                      y:130
                      anchors.left: d1so2b5.right
                      width:100
                      height:25
                      border.color: "gray"
                      TextInput{
                          id:decline
                          text:declinewarn
                          anchors.fill: parent
                          maximumLength: 8
                      }
                  }
                  Text{
                      id:d1so2b6
                      x:290;y:160
                      text:"增幅报警值:"
                      font.family:"Ubuntu"
                      font.pixelSize:25

                  }
                  Rectangle{
                      y:160
                      anchors.left: d1so2b6.right
                      width:100
                      height:25
                      border.color: "gray"
                      TextInput{
                          id:increase
                          text:increasewarn
                          anchors.fill: parent
                          maximumLength: 8
                      }
                  }

              }
              Rectangle{
                  x:25;y:20
                  width:185
                  height:25
                  Text{

                      text: "AI."+gas+"变量报警参数"
                      color:"blue"
                      font.family: "Ubuntu";
                      font.pixelSize: 20;
                  }
              }
              CheckBox {
                  x:40;y:250
                  text: "写入组态数据库"
                  font.family:"Ubuntu"
                  font.pixelSize:25
                  checked: true
              }
              Button{

                  text: "确定"
                  width: 60
                  height:40
                  x:360;y:250
                  onClicked: {
                      if(superhigh.length<1)
                          superhigh.text='0';
                      if(high.length<1)
                          high.text='0';
                      if(lower.length<1)
                          lower.text='0'
                      if(superlower.length<1)
                          superlower.text='0'
                      if(dead.length<1)
                          dead.text='0'
                      if(decline.length<1)
                          decline.text='0'
                      if(increase.length<1)
                          increase.text='0'
                      warninfo.updateWarnInfo(database_gas,superhigh.text,high.text,lower.text,
                                              superlower.text,dead.text,
                                              decline.text,increase.text)
                      g1SO2.close()

                  }

              }
              Button{

                  text: "取消"
                  width: 60
                  height:40
                  x:440;y:250
                  onClicked: {
                      g1SO2.close()
                  }
              }


          }
      }
  }
  Popup{
      id: g1NO2
      width: 1280
      height: 800
//      x: (parent.width - width) / 2
//      y: (parent.height - height) / 2
//      topPadding: 0
//      leftPadding: 0
//      rightPadding: 0
//      bottomPadding: 0
      modal: false
      focus: true

      closePolicy: Popup.CloseOnEscape | Popup.CloseOnPressOutsideParent
      background: Rectangle {
          implicitWidth: 1280
          implicitHeight: 800
          color: "transparent"
          border.color: "#444"
      }
          Rectangle{
              width: 600
              height: 400
              x: (parent.width - width) / 2
              y: (parent.height - height) / 2
              Rectangle {//标题栏
                  width: parent.width
                  height: 50
                  color: "#9cd9d8"
                  Text {
                      x: 20
                      anchors.verticalCenter: parent.verticalCenter
                      text: "设置变量报警..."
                      color: "white"
                  }
                  Image {
                      y: 5
                      width: 40
                      height: 40
                      anchors.right: parent.right
                      source: "qrc:///images/close.png"
                      MouseArea {
                          anchors.fill: parent
                          acceptedButtons: Qt.LeftButton

                          onClicked: {
                             g1NO2.close()
                          }
                      }
                  }
              }
              Rectangle{//内容栏
                  y:50
                  width: parent.width
                  height: parent.height-50
                  color: "white"
                  Rectangle{//设置矩形框
                      x:20;y:30

                      width:parent.width-40
                      height:200
                      radius: 5
                      border.color: "gray"
                      border.width: 2

                      CheckBox {
                          x:20;y:20
                          text: "允许报警(根据变量值)"
                          font.family:"Ubuntu"
                          font.pixelSize:25
                          checked: true
                      }
                      Text{
                          id:d1no2b
                          x:35;y:70
                          text:"超高报警值:"
                          font.family:"Ubuntu"
                          font.pixelSize:25

                      }
                      Rectangle{

                          y:70
                          anchors.left: d1no2b.right
                          width:100
                          height:25
                          border.color: "gray"
                          TextInput{
                              id:superhigh2
                              text:superhighwarn
                              anchors.fill: parent
                              maximumLength: 8
                          }
                      }
                      Text{
                          id:d1no2b1
                          x:60;y:100
                          text:"高报警值:"
                          font.family:"Ubuntu"
                          font.pixelSize:25

                      }
                      Rectangle{
                          y:100
                          anchors.left: d1no2b1.right
                          width:100
                          height:25
                          border.color: "gray"
                          TextInput{
                              id:high2
                              text:highwarn
                              anchors.fill: parent
                              maximumLength: 8
                          }
                      }
                      Text{
                          id:d1no2b2
                          x:60;y:130
                          text:"低报警值:"
                          font.family:"Ubuntu"
                          font.pixelSize:25

                      }
                      Rectangle{
                          y:130
                          anchors.left: d1no2b2.right
                          width:100
                          height:25
                          border.color: "gray"
                          TextInput{
                              id:low2
                              text:lowwarn
                              anchors.fill: parent
                              maximumLength: 8
                          }
                      }
                      Text{
                          id:d1no2b3
                          x:35;y:160
                          text:"超低报警值:"
                          font.family:"Ubuntu"
                          font.pixelSize:25

                      }
                      Rectangle{
                          y:160
                          anchors.left: d1no2b3.right
                          width:100
                          height:25
                          border.color: "gray"
                          TextInput{
                              id:superlow2
                              text:superlowwarn
                              anchors.fill: parent
                              maximumLength: 8
                          }
                      }
                      Text{
                          id:d1no2b4
                          x:325;y:85
                          text:"死区(%):"
                          font.family:"Ubuntu"
                          font.pixelSize:25

                      }
                      Rectangle{
                          y:85
                          width:100
                          height:25
                          anchors.left: d1no2b4.right
                          border.color: "gray"
                          TextInput{
                              id:dead2
                              text:deadwarn
                              anchors.fill: parent
                              maximumLength: 8
                          }
                      }
                      Text{
                          id:d1no2b5
                          x:290;y:130
                          text:"降幅报警值:"
                          font.family:"Ubuntu"
                          font.pixelSize:25

                      }
                      Rectangle{
                          y:130
                          anchors.left: d1no2b5.right
                          width:100
                          height:25
                          border.color: "gray"
                          TextInput{
                              id:decline2
                              text:declinewarn
                              anchors.fill: parent
                              maximumLength: 8
                          }
                      }
                      Text{
                          id:d1no2b6
                          x:290;y:160
                          text:"增幅报警值:"
                          font.family:"Ubuntu"
                          font.pixelSize:25

                      }
                      Rectangle{
                          y:160
                          anchors.left: d1no2b6.right
                          width:100
                          height:25
                          border.color: "gray"
                          TextInput{
                              id:increase2
                              text:increasewarn
                              anchors.fill: parent
                              maximumLength: 8
                          }
                      }

                  }
                  Rectangle{
                      x:25;y:20
                      width:225
                      height:25
                      Text{

                          text: "AI."+gas+"变量报警参数"
                          color:"blue"
                          font.family: "Ubuntu";
                          font.pixelSize: 20;
                      }
                  }
                  CheckBox {
                      x:40;y:250
                      text: "写入组态数据库"
                      font.family:"Ubuntu"
                      font.pixelSize:25
                      checked: true
                  }
                  Button{

                      text: "确定"
                      width: 60
                      height:40
                      x:360;y:250
                      onClicked: {
                          if(superhigh2.length<1)
                              superhigh2.text='0';
                          if(high2.length<1)
                              high2.text='0';
                          if(low2.length<1)
                              low2.text='0'
                          if(superlow2.length<1)
                              superlow2.text='0'
                          if(dead2.length<1)
                              dead2.text='0'
                          if(decline2.length<1)
                              decline2.text='0'
                          if(increase2.length<1)
                              increase2.text='0'
                          warninfo.updateWarnInfo(database_gas,superhigh2.text,high2.text,low2.text,
                                                  superlow2.text,dead2.text,
                                                  decline2.text,increase2.text)
                          g1NO2.close()
                      }

                  }
                  Button{

                      text: "取消"
                      width: 60
                      height:40
                      x:440;y:250
                      onClicked: {
                          g1NO2.close()
                      }
                  }


              }
          }

      //}

  }

  Popup{
      id: databaseRest
      width: 1280
      height: 800

//      x: (parent.width - width) / 2
//      y: (parent.height - height) / 2
//      topPadding: 0
//      leftPadding: 0
//      rightPadding: 0
//      bottomPadding: 0
      modal: false
      focus: true

      background: Rectangle {
          implicitWidth: 1280
          implicitHeight: 800
          color: "transparent"
          border.color: "#444"
      }
      closePolicy: Popup.CloseOnEscape | Popup.CloseOnPressOutsideParent
      Rectangle{

          width: 600
          height: 200
          x: (parent.width - width) / 2
          y: (parent.height - height) / 2
          Rectangle {//标题栏
              width: parent.width
              height: 30
              color: "lightblue"
              Text {
                  x: 20
                  anchors.verticalCenter: parent.verticalCenter
                  text: "提示："
                  color: "white"
              }
              Image {


                  width: 30
                  height: 30
                  anchors.right: parent.right
                  source: "qrc:///images/close.png"
                  MouseArea {
                      anchors.fill: parent
                      acceptedButtons: Qt.LeftButton

                      onClicked: {
                         databaseRest.close()

                      }
                  }
              }
          }
          Rectangle{//内容栏
              y:50
              width: parent.width
              height: parent.height-50
              color: "white"
              Text{
                  x:100;y:20
                  text: "还原数据库会造成原来数据丢失，请确认是否执行"
              }
              CheckBox{
                  x:120;y:80
                  text: "签名.."
              }
              Button{
                  x:320;y:80
                  width: 80
                  height: 40
                  text: "确定"
                  onClicked: databaseRest.close()
              }
              Button{
                  x:410;y:80
                  width: 80
                  height: 40
                  text: "取消"
                  onClicked: databaseRest.close()
              }


          }
      }
  }
  Popup{
      id: initial
      width: 1280
      height: 800


//      topPadding: 0
//      leftPadding: 0
//      rightPadding: 0
//      bottomPadding: 0
      modal: false
      focus: true


      closePolicy: Popup.CloseOnEscape | Popup.CloseOnPressOutsideParent
      background: Rectangle {
          implicitWidth: 1280
          implicitHeight: 800
          color: "transparent"
          border.color: "#444"
      }
      Rectangle{
          x: (parent.width - width) / 2
          y: (parent.height - height) / 2
          width: 600
          height: 200

          Rectangle {//标题栏
              width: parent.width
              height: 30
              color: "lightblue"
              Text {
                  x: 20
                  anchors.verticalCenter: parent.verticalCenter
                  text: "提示："
                  color: "white"
              }
              Image {


                  width: 30
                  height: 30
                  anchors.right: parent.right
                  source: "qrc:///images/close.png"
                  MouseArea {
                      anchors.fill: parent
                      acceptedButtons: Qt.LeftButton

                      onClicked: {
                         databaseRest.close()

                      }
                  }
              }
          }
          Rectangle{//内容栏
              y:50
              width: parent.width
              height: parent.height-50
              color: "white"
              Text{
                  x:100;y:20
                  text: "所有参数将恢复到出厂设置，请确认执行"
              }
              CheckBox{
                  x:120;y:80
                  text: "签名.."
              }
              Button{
                  x:320;y:80
                  width: 80
                  height: 40
                  text: "确定"
                  onClicked: initial.close()
              }
              Button{
                  x:410;y:80
                  width: 80
                  height: 40
                  text: "取消"
                  onClicked: initial.close()
              }


          }
      }
  }
  Popup{
      id: gasFlowset
      width: 1280
      height: 800

//      topPadding: 0
//      leftPadding: 0
//      rightPadding: 0
//      bottomPadding: 0
      modal: false
      focus: true

      background: Rectangle {
          implicitWidth: 1280
          implicitHeight: 800
          color: "transparent"
          border.color: "#444"
      }
      closePolicy: Popup.CloseOnEscape | Popup.CloseOnPressOutsideParent
      Rectangle{
          x: (parent.width - width) / 2
          y: (parent.height - height) / 2
          width: 400
          height: 400

          Rectangle {//标题栏
              width: parent.width
              height: 50
              color: "lightblue"
              Text {
                  x: 20
                  anchors.verticalCenter: parent.verticalCenter
                  text: "VA.@"+gas+"A"
                  color: "white"
              }
              Image {
                  y:5
                  width: 40
                  height: 40
                  anchors.right: parent.right
                  source: "qrc:///images/close.png"
                  MouseArea {
                      anchors.fill: parent
                      acceptedButtons: Qt.LeftButton

                      onClicked: {
                         gasFlowset.close()
                          passwd1.text=""
                      }
                  }
              }
          }
          Rectangle{
              y:50
              width: parent.width
              height: parent.height-50
              Rectangle{
                  width: 200
                  height: 30
                  x:50;y:10
                  border.color: "black"
                  TextInput{
                      id:passwd1
                      width: parent.width
                      height: parent.height

                  }
              }
              Grid {
                  id:number
                  x:40
                  y:50
                  width: 200
                  height:250
                  padding: 10
                  columns: 3
                  rows: 4
                  Button {
                      id: button1
                      width: 50
                      height:50
                      text: qsTr("1")
                      onClicked: passwd1.insert(passwd1.text.length,"1")
                  }
                  Button {
                      id: button2
                      width: 50
                      height:50
                      text: qsTr("2")
                      onClicked: passwd1.insert(passwd1.text.length,"2")
                  }
                  Button {
                      id: button3
                      width: 50
                      height:50
                      text: qsTr("3")
                      onClicked: passwd1.insert(passwd1.text.length,"3")
                  }
                  Button {
                      id: button4
                      width: 50
                      height:50
                      text: qsTr("4")
                      onClicked: passwd1.insert(passwd1.text.length,"4")
                  }
                  Button {
                      id: button5
                      width: 50
                      height:50
                      text: qsTr("5")
                      onClicked: passwd1.insert(passwd1.text.length,"5")
                  }
                  Button {
                      id: button6
                      width: 50
                      height:50
                      text: qsTr("6")
                      onClicked: passwd1.insert(passwd1.text.length,"6")
                  }
                  Button {
                      id: button7
                      width: 50
                      height:50
                      text: qsTr("7")
                      onClicked: passwd1.insert(passwd1.text.length,"7")
                  }
                  Button {
                      id: button8
                      width: 50
                      height:50
                      text: qsTr("8")
                      onClicked: passwd1.insert(passwd1.text.length,"8")
                  }
                  Button {
                      id: button9
                      width: 50
                      height:50
                      text: qsTr("9")
                      onClicked: passwd1.insert(passwd1.text.length,"9")
                  }
                  Button {
                      id: button0
                      width: 50
                      height:50
                      text: qsTr("0")
                      onClicked: passwd1.insert(passwd1.text.length,"0")
                  }
                  Button {
                      id: button10
                      width: 50
                      height:50
                      text: qsTr(".")
                      onClicked: passwd1.insert(passwd1.text.length,".")
                  }
                  Button {
                      id: button11
                      width: 50
                      height:50
                      text: qsTr("-")
                      onClicked: passwd1.insert(passwd1.text.length,"-")
                  }

              }
              Button{
                  id: button12
                  x:210;y:60
                  width: 50
                  height:50
                  text: qsTr("<-")
                  onClicked: passwd1.remove(passwd1.text.length-1,passwd1.text.length)
              }
              Button{
                  x:280;y:12
                  width: 60
                  height: 30
                  text: "确认"
                  onClicked: {
                      if (gas_flow.match("pitot_tube")&&guolu==1)
                      {
                          pit1.text=passwd1.text
                          passwd1.text=""
                      }
                      if (gas_flow.match("velocity_field")&&guolu==1)
                      {
                          vel1.text=passwd1.text
                          passwd1.text=""
                      }
                      if (gas_flow.match("sectional_area")&&guolu==1)
                      {
                          sec1.text=passwd1.text
                          passwd1.text=""
                      }
                      if (gas_flow.match("pitot_tube")&&guolu==2)
                      {
                          pit2.text=passwd1.text
                          passwd1.text=""
                      }
                      if (gas_flow.match("velocity_field")&&guolu==2)
                      {
                          vel2.text=passwd1.text
                          passwd1.text=""
                      }
                      if (gas_flow.match("sectional_area")&&guolu==2)
                      {
                          sec2.text=passwd1.text
                          passwd1.text=""
                      }
                      gasFlowset.close()
                  }
              }
              Button{
                  x:280;y:50
                  width: 60
                  height: 30
                  text: "取消"
                  onClicked:
                  {
                      passwd1.text=""
                      gasFlowset.close()
                  }
              }

          }

      }
  }
  Popup{
      id: particulate
      width: 1280
      height: 800

//      topPadding: 0
//      leftPadding: 0
//      rightPadding: 0
//      bottomPadding: 0
      modal: false
      focus: true

      background: Rectangle {
          implicitWidth: 1280
          implicitHeight: 800
          color: "transparent"
          border.color: "#444"
      }
      closePolicy: Popup.CloseOnEscape | Popup.CloseOnPressOutsideParent
      Rectangle{
          x: (parent.width - width) / 2
          y: (parent.height - height) / 2
          width: 400
          height: 400

          Rectangle {//标题栏
              width: parent.width
              height: 50
              color: "lightblue"
              Text {
                  x: 20
                  anchors.verticalCenter: parent.verticalCenter
                  text: "VA.@"+gas
                  color: "white"
              }
              Image {
                  y:5
                  width: 40
                  height: 40
                  anchors.right: parent.right
                  source: "qrc:///images/close.png"
                  MouseArea {
                      anchors.fill: parent
                      acceptedButtons: Qt.LeftButton

                      onClicked: {
                         particulate.close()
                          passwd2.text=""
                      }
                  }
              }
          }
          Rectangle{
              y:50
              width: parent.width
              height: parent.height-50
              Rectangle{
                  width: 200
                  height: 30
                  x:50;y:10
                  border.color: "black"
                  TextInput{
                      id:passwd2
                      width: parent.width
                      height: parent.height

                  }
              }
              Grid {

                  x:40
                  y:50
                  width: 200
                  height:250
                  padding: 10
                  columns: 3
                  rows: 4
                  Button {

                      width: 50
                      height:50
                      text: qsTr("1")
                      onClicked: passwd2.insert(passwd2.text.length,"1")
                  }
                  Button {

                      width: 50
                      height:50
                      text: qsTr("2")
                      onClicked: passwd2.insert(passwd2.text.length,"2")
                  }
                  Button {

                      width: 50
                      height:50
                      text: qsTr("3")
                      onClicked: passwd2.insert(passwd2.text.length,"3")
                  }
                  Button {

                      width: 50
                      height:50
                      text: qsTr("4")
                      onClicked: passwd2.insert(passwd2.text.length,"4")
                  }
                  Button {

                      width: 50
                      height:50
                      text: qsTr("5")
                      onClicked: passwd2.insert(passwd2.text.length,"5")
                  }
                  Button {

                      width: 50
                      height:50
                      text: qsTr("6")
                      onClicked: passwd2.insert(passwd2.text.length,"6")
                  }
                  Button {

                      width: 50
                      height:50
                      text: qsTr("7")
                      onClicked: passwd2.insert(passwd2.text.length,"7")
                  }
                  Button {

                      width: 50
                      height:50
                      text: qsTr("8")
                      onClicked: passwd2.insert(passwd2.text.length,"8")
                  }
                  Button {

                      width: 50
                      height:50
                      text: qsTr("9")
                      onClicked: passwd2.insert(passwd2.text.length,"9")
                  }
                  Button {

                      width: 50
                      height:50
                      text: qsTr("0")
                      onClicked: passwd2.insert(passwd2.text.length,"0")
                  }
                  Button {

                      width: 50
                      height:50
                      text: qsTr(".")
                      onClicked: passwd2.insert(passwd2.text.length,".")
                  }
                  Button {

                      width: 50
                      height:50
                      text: qsTr("-")
                      onClicked: passwd2.insert(passwd2.text.length,"-")
                  }

              }
              Button{

                  x:210;y:60
                  width: 50
                  height:50
                  text: qsTr("<-")
                  onClicked: passwd2.remove(passwd2.text.length-1,passwd2.text.length)
              }
              Button{
                  x:280;y:12
                  width: 60
                  height: 30
                  text: "确认"
                  onClicked: {
                      if (parti_name.match("dusta1")&&guolu==1)
                      {
                          dust_degreea1.text=passwd2.text
                          passwd2.text=""
                      }
                      if (parti_name.match("dustb1")&&guolu==1)
                      {
                          dust_degreeb1.text=passwd2.text
                          passwd2.text=""
                      }
                      if (parti_name.match("dustc1")&&guolu==1)
                      {
                          dust_degreec1.text=passwd2.text
                          passwd2.text=""
                      }
                      if (parti_name.match("dusta2")&&guolu==2)
                      {
                          dust_degreea2.text=passwd2.text
                          passwd2.text=""
                      }
                      if (parti_name.match("dustb2")&&guolu==2)
                      {
                          dust_degreeb2.text=passwd2.text
                          passwd2.text=""
                      }
                      if (parti_name.match("dustc2")&&guolu==2)
                      {
                          dust_degreec2.text=passwd2.text
                          passwd2.text=""
                      }
                      particulate.close()
                  }
              }
              Button{
                  x:280;y:50
                  width: 60
                  height: 30
                  text: "取消"
                  onClicked:
                  {
                      passwd2.text=""
                      particulate.close()
                  }
              }

          }

      }
  }
  Popup{
      id: atmospara
          width: 1280
          height: 800

    //      topPadding: 0
    //      leftPadding: 0
    //      rightPadding: 0
    //      bottomPadding: 0
          modal: false
          focus: true

          background: Rectangle {
              implicitWidth: 1280
              implicitHeight: 800
              color: "transparent"
              border.color: "#444"
          }
          closePolicy: Popup.CloseOnEscape | Popup.CloseOnPressOutsideParent
          Rectangle{
              x: (parent.width - width) / 2
              y: (parent.height - height) / 2
              width: 400
              height: 400

              Rectangle {//标题栏
                  width: parent.width
                  height: 50
                  color: "lightblue"
                  Text {
                      x: 20
                      anchors.verticalCenter: parent.verticalCenter
                      text: "VA.@"+gas
                      color: "white"
                  }
                  Image {
                      y:5
                      width: 40
                      height: 40
                      anchors.right: parent.right
                      source: "qrc:///images/close.png"
                      MouseArea {
                          anchors.fill: parent
                          acceptedButtons: Qt.LeftButton

                          onClicked: {
                             atmospara.close()
                              passwd3.text=""
                          }
                      }
                  }
              }
              Rectangle{
                  y:50
                  width: parent.width
                  height: parent.height-50
                  Rectangle{
                      width: 200
                      height: 30
                      x:50;y:10
                      border.color: "black"
                      TextInput{
                          id:passwd3
                          width: parent.width
                          height: parent.height

                      }
                  }
                  Grid {

                      x:40
                      y:50
                      width: 200
                      height:250
                      padding: 10
                      columns: 3
                      rows: 4
                      Button {

                          width: 50
                          height:50
                          text: qsTr("1")
                          onClicked: passwd3.insert(passwd3.text.length,"1")
                      }
                      Button {

                          width: 50
                          height:50
                          text: qsTr("2")
                          onClicked: passwd3.insert(passwd3.text.length,"2")
                      }
                      Button {

                          width: 50
                          height:50
                          text: qsTr("3")
                          onClicked: passwd3.insert(passwd3.text.length,"3")
                      }
                      Button {

                          width: 50
                          height:50
                          text: qsTr("4")
                          onClicked: passwd3.insert(passwd3.text.length,"4")
                      }
                      Button {

                          width: 50
                          height:50
                          text: qsTr("5")
                          onClicked: passwd3.insert(passwd3.text.length,"5")
                      }
                      Button {

                          width: 50
                          height:50
                          text: qsTr("6")
                          onClicked: passwd3.insert(passwd3.text.length,"6")
                      }
                      Button {

                          width: 50
                          height:50
                          text: qsTr("7")
                          onClicked: passwd3.insert(passwd3.text.length,"7")
                      }
                      Button {

                          width: 50
                          height:50
                          text: qsTr("8")
                          onClicked: passwd3.insert(passwd3.text.length,"8")
                      }
                      Button {

                          width: 50
                          height:50
                          text: qsTr("9")
                          onClicked: passwd3.insert(passwd3.text.length,"9")
                      }
                      Button {

                          width: 50
                          height:50
                          text: qsTr("0")
                          onClicked: passwd3.insert(passwd3.text.length,"0")
                      }
                      Button {

                          width: 50
                          height:50
                          text: qsTr(".")
                          onClicked: passwd3.insert(passwd3.text.length,".")
                      }
                      Button {

                          width: 50
                          height:50
                          text: qsTr("-")
                          onClicked: passwd3.insert(passwd3.text.length,"-")
                      }

                  }
                  Button{

                      x:210;y:60
                      width: 50
                      height:50
                      text: qsTr("<-")
                      onClicked: passwd3.remove(passwd3.text.length-1,passwd3.text.length)
                  }
                  Button{
                      x:280;y:12
                      width: 60
                      height: 30
                      text: "确认"
                      onClicked: {
                          if (parti_name.match("atmospress"))
                          {
                              atomapress.text=passwd3.text
                              passwd3.text=""
                          }
                          if (parti_name.match("atmospara"))
                          {
                              atomapara.text=passwd3.text
                              passwd3.text=""
                          }


                          atmospara.close()
                      }
                  }
                  Button{
                      x:280;y:50
                      width: 60
                      height: 30
                      text: "取消"
                      onClicked:
                      {
                          passwd3.text=""
                          atmospara.close()
                      }
                  }

              }

          }
      }

        }

    }
Popup{
    id:login_control
    x: (mainwindow.width - width) / 2
    y: (mainwindow.height - height) / 2
    topPadding: 0
    leftPadding: 0
    rightPadding: 0
    bottomPadding: 0
    width:500
    height: 250
    closePolicy: "CloseOnPressOutside"||"CloseOnPressOutsideParent"
    Rectangle{

        width: parent.width
        height: parent.height
        Rectangle {//标题栏
            width: parent.width
            height: 30
            color: "lightblue"
            Text {
                x: 20
                anchors.verticalCenter: parent.verticalCenter
                text: "提示："
                color: "white"
            }
            Image {


                width: 30
                height: 30
                anchors.right: parent.right
                source: "qrc:///images/close.png"
                MouseArea {
                    anchors.fill: parent
                    acceptedButtons: Qt.LeftButton

                    onClicked: {
                       login_control.close()

                    }
                }
            }
        }
Rectangle{
    y:50
    width: parent.width
    height:parent.height-50
    Text{
        text:"当前模块只供管理员使用，请向管理员申请！"
        font.family: "Ubuntu"
        font.pixelSize: 20
        x: (parent.width - width) / 2
        y: (parent.height - height) / 2
    }
}
    }
}
}




